| Constructor and Description |
|---|
Rot() |
Rot(float a) |
Rot(Point center,
Point prev,
Point curr) |
Rot(Vec from,
Vec to) |
| Modifier and Type | Method and Description |
|---|---|
float |
angle() |
void |
compose(Rotation r)
Compose the rotation
|
static Rotation |
compose(Rotation r1,
Rotation r2) |
boolean |
equals(Object obj) |
void |
fromMatrix(Mat glMatrix)
Sets the rotation from the given Mat representation.
|
void |
fromRotatedBasis(Vec X,
Vec Y,
Vec Z)
Sets the rotation from the three rotated vectors of an orthogonal basis.
|
void |
fromTo(Vec from,
Vec to)
Define orientation from the two vectors.
|
Rot |
get()
Returns a deep copy of the object.
|
int |
hashCode() |
Rotation |
inverse()
Returns the inverse rotation
|
Mat |
inverseMatrix()
Returns the associated inverse rotation Mat.
|
Vec |
inverseRotate(Vec v)
Returns the image of
v by the Rotation.inverse() rotation. |
Mat |
matrix()
Returns the Mat which represents the rotation matrix associated with the Quat.
|
void |
negate()
Negates all object components
|
float |
normalize()
Normalizes the rotation
|
float |
normalize(boolean onlypos) |
void |
print()
Prints orientation data.
|
Vec |
rotate(Vec v)
Returns the image of
v by the rotation. |
public Rot get()
Copyable
Typical implementation should simple look like: return new Object(this).
public void negate()
Rotationpublic Rotation inverse()
Rotationpublic Vec rotate(Vec v)
Rotationv by the rotation.public Vec inverseRotate(Vec v)
Rotationv by the Rotation.inverse() rotation.inverseRotate in interface Rotationpublic Mat matrix()
Rotationpublic Mat inverseMatrix()
RotationRotation.matrix() of the
Rotation.inverse().inverseMatrix in interface Rotationpublic void fromMatrix(Mat glMatrix)
RotationfromMatrix in interface Rotationpublic void fromRotatedBasis(Vec X, Vec Y, Vec Z)
Rotation
The three vectors do not have to be normalized but must be orthogonal and direct
(i,e., X^Y=k*Z, with k>0).
fromRotatedBasis in interface Rotationpublic final void compose(Rotation r)
Rotationpublic float normalize(boolean onlypos)
public float normalize()
Rotationpublic void fromTo(Vec from, Vec to)
RotationProcessing Library proscene by Jean Pierre Charalambos. (c) 2014-2017 National University of Colombia