|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.openmali.vecmath2.TupleNf<Tuple3f>
org.openmali.vecmath2.Tuple3f
org.openmali.vecmath2.AxisAngle3f
public class AxisAngle3f
A 4 element axis angle represented by single precision floating point x,y,z,angle components. An axis angle is a rotation of angle (radians) about the vector (x,y,z). Inspired by Kenji Hiranabe's AxisAngle3f implementation
| Field Summary | |
|---|---|
static AxisAngle3f |
ZERO
|
| Fields inherited from class org.openmali.vecmath2.TupleNf |
|---|
isDirty, roTrick, values |
| Constructor Summary | |
|---|---|
|
AxisAngle3f()
Constructs and initializes a AxisAngle3f to (0,0,1,0). |
|
AxisAngle3f(AxisAngle3f aa3f)
Constructs and initializes a AxisAngle3f from the specified AxisAngle3f. |
protected |
AxisAngle3f(boolean readOnly)
Constructs and initializes a AxisAngle3f to (0,0,1,0). |
protected |
AxisAngle3f(boolean readOnly,
AxisAngle3f aa3f)
Constructs and initializes a AxisAngle3f from the specified AxisAngle3f. |
protected |
AxisAngle3f(boolean readOnly,
float[] values)
Constructs and initializes an AxisAngle3f from the components contained in the array. |
protected |
AxisAngle3f(boolean readOnly,
float x,
float y,
float z,
float angle)
Constructs and initializes an AxisAngle3f from the specified x, y, z, and angle. |
protected |
AxisAngle3f(boolean readOnly,
Tuple3f axis,
float angle)
Constructs and initializes an AxisAngle3f from the specified axis and angle. |
|
AxisAngle3f(float[] values)
Constructs and initializes an AxisAngle3f from the components contained in the array. |
|
AxisAngle3f(float x,
float y,
float z,
float angle)
Constructs and initializes an AxisAngle3f from the specified x, y, z, and angle. |
|
AxisAngle3f(Tuple3f axis,
float angle)
Constructs and initializes an AxisAngle3f from the specified axis and angle. |
| Method Summary | |
|---|---|
AxisAngle3f |
addAngle(float v)
Adds v to this tuple's angle value. |
AxisAngle3f |
clone()
Creates and returns a copy of this object. |
int |
deserialize(int pos,
byte[] buffer)
Deserializes this instanc'es data from the byte array. |
AxisAngle3f |
divAngle(float v)
Divides this tuple's angle value by v. |
boolean |
epsilonEquals(AxisAngle3f aa3f,
float epsilon)
Returns true if the L-infinite distance between this axis-angle and axis-angle t1 is less than or equal to the epsilon parameter, otherwise returns false. |
boolean |
equals(AxisAngle3f aa3f)
Returns true if all of the data members of AxisAngle3f t1 are equal to the corresponding data members in this. |
boolean |
equals(java.lang.Object o)
Returns true if the Object o1 is of type AxisAngle3f and all of the data members of o1 are equal to the corresponding data members in this AxisAngle3f. |
static AxisAngle3f |
fromPool()
Allocates an AxisAngle3f instance from the pool. |
static AxisAngle3f |
fromPool(AxisAngle3f aa)
Allocates an AxisAngle3f instance from the pool. |
static AxisAngle3f |
fromPool(float x,
float y,
float z,
float angle)
Allocates an AxisAngle3f instance from the pool. |
void |
get(float[] buffer)
Gets the value of this axis angle into the array a of length four in x,y,z,angle order. |
float |
getAngle()
|
protected int |
getSerializationBufferSize()
|
int |
hashCode()
Returns a hash number based on the data values in this object. |
AxisAngle3f |
mulAngle(float v)
Multiplies this tuple's angle value with v. |
static AxisAngle3f |
newReadOnly()
Constructs and initializes a AxisAngle3f to (0,0,1,0). |
static AxisAngle3f |
newReadOnly(AxisAngle3f aa3f)
Constructs and initializes a AxisAngle3f from the specified AxisAngle3f. |
static AxisAngle3f |
newReadOnly(float[] values)
Constructs and initializes an AxisAngle3f from the components contained in the array. |
static AxisAngle3f |
newReadOnly(float x,
float y,
float z,
float angle)
Constructs and initializes an AxisAngle3f from the specified x, y, z, and angle. |
static AxisAngle3f |
newReadOnly(Tuple3f axis,
float angle)
Constructs and initializes an AxisAngle3f from the specified axis and angle. |
int |
serialize(int pos,
byte[] buffer)
Serializes this instanc'es data into the byte array. |
void |
set(AxisAngle3f aa3f)
Sets the value of this axis angle to the value of axis angle t1. |
AxisAngle3f |
set(float[] values)
Sets the value of this axis angle from the 4 values specified in the array. |
void |
set(float x,
float y,
float z,
float angle)
Sets the value of this axis angle to the specified x,y,z,angle. |
void |
set(Matrix3f mat)
Sets the value of this axis-angle to the rotational component of the passed matrix. |
void |
set(Matrix4f mat)
Sets the value of this axis-angle to the rotational component of the passed matrix. |
void |
set(Quaternion4f quat)
Sets the value of this axis-angle to the rotational equivalent of the passed quaternion. |
void |
set(Tuple3f axis,
float angle)
Sets the value of this AxisAngle3f to the specified axis and angle. |
void |
setAngle(float angle)
Sets the value of the angle of this tuple. |
AxisAngle3f |
subAngle(float v)
Subtracts v from this tuple's angle value. |
static void |
toPool(AxisAngle3f o)
Stores the given AxisAngle3f instance in the pool. |
java.lang.String |
toString()
Returns a string that contains the values of this AxisAngle3f. |
| Methods inherited from class org.openmali.vecmath2.Tuple3f |
|---|
add, addX, addY, addZ, div, divX, divY, divZ, fromPool, fromPool, getX, getY, getZ, mul, mulX, mulY, mulZ, newReadOnly, newReadOnly, scale, set, setX, setY, setZ, sub, subX, subY, subZ, toPool |
| Methods inherited from class org.openmali.vecmath2.TupleNf |
|---|
absolute, absolute, add, add, addValue, clamp, clamp, clampMax, clampMax, clampMin, clampMin, div, divValue, epsilonEquals, equals, fill, get, getSize, getValue, interpolate, interpolate, isDirty, isReadOnly, mul, mulValue, negate, negate, readExternal, round, round, scale, scale, scaleAdd, scaleAdd, set, setClean, setValue, setZero, sub, sub, subValue, writeExternal, writeToBuffer, writeToBuffer |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.io.Externalizable |
|---|
readExternal, writeExternal |
| Methods inherited from interface org.openmali.vecmath2.TupleInterface |
|---|
absolute, absolute, add, add, addValue, clamp, clamp, clampMax, clampMax, clampMin, clampMin, div, divValue, epsilonEquals, fill, get, getSize, getValue, interpolate, interpolate, isDirty, isReadOnly, mul, mulValue, negate, negate, round, round, scale, scale, scaleAdd, scaleAdd, set, setClean, setValue, setZero, sub, sub, subValue |
| Field Detail |
|---|
public static final AxisAngle3f ZERO
| Constructor Detail |
|---|
protected AxisAngle3f(boolean readOnly,
float x,
float y,
float z,
float angle)
readOnly - x - the x coordinatey - the y coordinatez - the z coordinateangle - the angle.
protected AxisAngle3f(boolean readOnly,
float[] values)
readOnly - values - the array of length 4 containing x,y,z,angle in order
protected AxisAngle3f(boolean readOnly,
AxisAngle3f aa3f)
readOnly - aa3f - the AxisAngle3f containing the initialization x y z angle data
protected AxisAngle3f(boolean readOnly,
Tuple3f axis,
float angle)
readOnly - axis - the axisangle - the angleprotected AxisAngle3f(boolean readOnly)
readOnly -
public AxisAngle3f(float x,
float y,
float z,
float angle)
x - the x coordinatey - the y coordinatez - the z coordinateangle - the angle.public AxisAngle3f(float[] values)
values - the array of length 4 containing x,y,z,angle in orderpublic AxisAngle3f(AxisAngle3f aa3f)
aa3f - the AxisAngle3f containing the initialization x y z angle data
public AxisAngle3f(Tuple3f axis,
float angle)
axis - the axisangle - the anglepublic AxisAngle3f()
| Method Detail |
|---|
public final void setAngle(float angle)
angle - public final float getAngle()
public final void set(Tuple3f axis,
float angle)
axis - the axisangle - the angle
public final void set(float x,
float y,
float z,
float angle)
x - the x coordinatey - the y coordinatez - the z coordinateangle - the anglepublic final AxisAngle3f set(float[] values)
set in interface TupleInterface<Tuple3f>set in class TupleNf<Tuple3f>values - the array of length 4 containing x,y,z,angle in order
public final void set(AxisAngle3f aa3f)
aa3f - the axis angle to be copiedpublic final void get(float[] buffer)
get in interface TupleInterface<Tuple3f>get in class TupleNf<Tuple3f>buffer - the array of length fourpublic final void set(Matrix4f mat)
mat - the matrix4fpublic final void set(Matrix3f mat)
mat - the matrix3fpublic final void set(Quaternion4f quat)
quat - the Quat4fpublic final AxisAngle3f addAngle(float v)
v -
public final AxisAngle3f subAngle(float v)
v -
public final AxisAngle3f mulAngle(float v)
v -
public final AxisAngle3f divAngle(float v)
v -
public java.lang.String toString()
toString in class TupleNf<Tuple3f>public int hashCode()
hashCode in class TupleNf<Tuple3f>public boolean equals(AxisAngle3f aa3f)
aa3f - the AxisAngle with which the comparison is madepublic boolean equals(java.lang.Object o)
equals in class Tuple3fo - the object with which the comparison is made.
public boolean epsilonEquals(AxisAngle3f aa3f,
float epsilon)
aa3f - the axis-angle to be compared to this axis-angleepsilon - the threshold valuepublic AxisAngle3f clone()
clone in class Tuple3fCloneable
public int serialize(int pos,
byte[] buffer)
serialize in class TupleNf<Tuple3f>
public int deserialize(int pos,
byte[] buffer)
deserialize in class TupleNf<Tuple3f>protected int getSerializationBufferSize()
getSerializationBufferSize in class TupleNf<Tuple3f>
public static AxisAngle3f newReadOnly(float x,
float y,
float z,
float angle)
x - the x coordinatey - the y coordinatez - the z coordinateangle - the angle.public static AxisAngle3f newReadOnly(float[] values)
values - the array of length 4 containing x,y,z,angle in orderpublic static AxisAngle3f newReadOnly(AxisAngle3f aa3f)
aa3f - the AxisAngle3f containing the initialization x y z angle data
public static AxisAngle3f newReadOnly(Tuple3f axis,
float angle)
axis - the axisangle - the anglepublic static AxisAngle3f newReadOnly()
public static AxisAngle3f fromPool()
public static AxisAngle3f fromPool(float x,
float y,
float z,
float angle)
public static AxisAngle3f fromPool(AxisAngle3f aa)
public static void toPool(AxisAngle3f o)
o -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||