Describes object transformation in 3D space.
new Transformation2d(
rotation?,translation?,scaleFactor?):Transformation2d
Rotation matrix of the transformation.
Translation vector of the transformation.
number
Scale factor.
new Transformation2d(
point,angle,translation?):Transformation2d
Rotation point.
number
Rotation angle.
Translation vector of the transformation.
rotation:
Matrix2d
Rotation matrix of the transformation
scaleFactor:
number=1
Scale factor
translation:
Vector2d
Translation vector of the transformation
clone():
Transformation2d
Creates new Transformation2d object same as this.
copy(
other):this
Copies other transformation to this.
Copied object.
this
invert():
this
Inverts this transformation.
this
inverted():
Transformation2d
Returns new Point object received by performing a invert() operation to this object.
isEqual(
other):boolean
Returns true if other transformation is equal to this transformation.
Other transformation.
boolean
isIdentity():
boolean
Returns true if transformation is identity.
boolean
isNegative():
boolean
Returns true if rotation matrix determinant less than 0.
boolean
multiplied(
other):Transformation2d
Returns new Transformation2d object received by performing a multiply() operation to this object.
Other transformation.
multiply(
other):this
Multiplies this transformation with other.
Other transformation.
this
power(
num):this
Powers this transformation.
number
Power value.
this
powered(
num):Transformation2d
Returns new Transformation2d object received by performing a power() operation to this object.
number
Power value.
resetToIdentity():
this
Resets this transformation to identity transformation.
this
rotationAngle():
number
Returns rotation angle in radians.
number
setRotation(
matrix):this
Sets rotation matrix of transformation.
Rotation matrix.
this
setRotation(
point,angle):this
Sets transformation as rotation around point on angle.
Rotation point.
number
Rotation angle.
this
setScaleFactor(
scaleFactor):this
Sets scale factor of transformation.
number
Scale factor.
this
setTranslation(
vector):this
Sets translation vector of transformation.
Translation vector.
this
setTranslation(
point1,point2):this
Sets translation vector of transformation.
First point of translation vector.
Second point of translation vector.
this
staticmirrorTransformation(point):Transformation2d
Returns new Transformation2d object that represent mirror transformation relative to the point.
Mirror point.
staticmirrorTransformation(axis):Transformation2d
Returns new Transformation2d object that represent mirror transformation relative to the axis.
Mirror axis.
staticrotateTransformation(point,angle):Transformation2d
Returns new Transformation2d object that represent rotate transformation.
Rotation point.
number
Rotation angle.
staticscaleTransformation(point,scale):Transformation2d
Returns new Transformation2d object that represent scale transformation.
Point.
number
Scale.
statictranslateTransformation(vector):Transformation2d
Returns new Transformation2d object that represent translate transformation.
Translation vector.