public class IdentityTransform extends AbstractTransform
Modifier and Type | Field and Description |
---|---|
static int |
GENERALITY
Identifies the identity transform in
generality() . |
Constructor and Description |
---|
IdentityTransform() |
Modifier and Type | Method and Description |
---|---|
Transform |
concatenate(Transform other)
Returns a new transform comprised of the concatenation of
other to this transform
(i.e. |
IdentityTransform |
copy()
Returns a copy of this transform.
|
int |
generality()
Returns an integer that increases monotonically with the generality of the transform
implementation.
|
void |
get(float[] matrix)
Copies the affine transform matrix into the supplied array.
|
Point |
inverseTransform(IPoint p,
Point into)
Inverse transforms the supplied point, writing the result into
into . |
Vector |
inverseTransform(IVector v,
Vector into)
Inverse transforms the supplied vector, writing the result into
into . |
Transform |
invert()
Returns a new transform that represents the inverse of this transform.
|
Transform |
lerp(Transform other,
float t)
Returns a new transform comprised of the linear interpolation between this transform and
the specified other.
|
Transform |
preConcatenate(Transform other)
Returns a new transform comprised of the concatenation of this transform to
other
(i.e. |
float |
rotation()
Returns the rotation applied by this transform.
|
float |
scaleX()
Returns the x-component of the scale applied by this transform.
|
float |
scaleY()
Returns the y-component of the scale applied by this transform.
|
String |
toString() |
void |
transform(float[] src,
int srcOff,
float[] dst,
int dstOff,
int count)
Transforms the supplied points.
|
void |
transform(IPoint[] src,
int srcOff,
Point[] dst,
int dstOff,
int count)
Transforms the supplied points.
|
Point |
transform(IPoint p,
Point into)
Transforms the supplied point, writing the result into
into . |
Vector |
transform(IVector v,
Vector into)
Transforms the supplied vector, writing the result into
into . |
Vector |
transformPoint(IVector v,
Vector into)
Transforms the supplied vector as a point (accounting for translation), writing the result
into
into . |
float |
tx()
Returns the x-coordinate of the translation component.
|
float |
ty()
Returns the y-coordinate of the translation component.
|
float |
uniformScale()
Returns the uniform scale applied by this transform.
|
clone, rotate, scale, scale, scaleX, scaleY, setRotation, setScale, setScaleX, setScaleY, setTransform, setTranslation, setTx, setTy, setUniformScale, shear, shearX, shearY, translate, translateX, translateY, translation, uniformScale
public static final int GENERALITY
generality()
.public float uniformScale()
Transform
public float scaleX()
Transform
public float scaleY()
Transform
public float rotation()
Transform
public float tx()
Transform
public float ty()
Transform
public void get(float[] matrix)
Transform
matrix
- the array which receives m00, m01, m10, m11, tx, ty
.public Transform invert()
Transform
public Transform concatenate(Transform other)
Transform
other
to this transform
(i.e. this x other
).public Transform preConcatenate(Transform other)
Transform
other
(i.e. other x this
).public Transform lerp(Transform other, float t)
Transform
public Point transform(IPoint p, Point into)
Transform
into
.into
- a point into which to store the result, may be the same object as p
.into
for chaining.public void transform(IPoint[] src, int srcOff, Point[] dst, int dstOff, int count)
Transform
src
- the points to be transformed.srcOff
- the offset into the src
array at which to start.dst
- the points into which to store the transformed points. May be src
.dstOff
- the offset into the dst
array at which to start.count
- the number of points to transform.public void transform(float[] src, int srcOff, float[] dst, int dstOff, int count)
Transform
src
- the points to be transformed (as [x, y, x, y, ...]
).srcOff
- the offset into the src
array at which to start.dst
- the points into which to store the transformed points. May be src
.dstOff
- the offset into the dst
array at which to start.count
- the number of points to transform.public Point inverseTransform(IPoint p, Point into)
Transform
into
.into
- a point into which to store the result, may be the same object as p
.into
, for chaining.public Vector transformPoint(IVector v, Vector into)
Transform
into
.into
- a vector into which to store the result, may be the same object as v
.into
, for chaining.public Vector transform(IVector v, Vector into)
Transform
into
.into
- a vector into which to store the result, may be the same object as v
.into
, for chaining.public Vector inverseTransform(IVector v, Vector into)
Transform
into
.into
- a vector into which to store the result, may be the same object as v
.into
, for chaining.public IdentityTransform copy()
Transform
copy
in interface Transform
copy
in class AbstractTransform
public int generality()
Transform
Copyright © 2017. All rights reserved.