Top Description Fields Constructors Methods
com.sun.javafx.geom

public Class Quat4f

extends Object
Class Inheritance

A 4 element unit quaternion represented by single precision floating point x,y,z,w coordinates. The quaternion is always normalized.

Field Summary

Modifier and TypeField and Description
pack-priv static final double
public float
w

The w coordinate.

public float
x

The x coordinate.

public float
y

The y coordinate.

public float
z

The z coordinate.

Constructor Summary

AccessConstructor and Description
public
Quat4f()

Constructs and initializes a Quat4f to (0,0,0,0).

public
Quat4f(float
the x coordinate
x
,
float
the y coordinate
y
,
float
the z coordinate
z
,
float
the w scalar component
w
)

Constructs and initializes a Quat4f from the specified xyzw coordinates.

public
Quat4f(float[]
the array of length 4 containing xyzw in order
q
)

Constructs and initializes a Quat4f from the array of length 4.

public
Quat4f(Quat4f
the Quat4f containing the initialization x y z w data
q1
)

Constructs and initializes a Quat4f from the specified Quat4f.

Method Summary

Modifier and TypeMethod and Description
public final void
normalize()

Normalizes the value of this quaternion in place.

public final void
scale(float
the scalar value
s
)

Sets the value of this Quat4f to the scalar multiplication of the scale factor with this.

public final void
set(Matrix3f
the Matrix3f
m1
)

Sets the value of this quaternion to the rotational component of the passed matrix.

public final void
set(float[][]
the float[3][3] matrix
m1
)

Sets the value of this quaternion to the rotational component of the passed float matrix.

public String

Returns:

a string representation of this Quat4f.
toString
()

Overrides java.lang.Object.toString.

Returns a String that represents the value of this Quat4f.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

EPS2back to summary
pack-priv static final double EPS2
wback to summary
public float w

The w coordinate.

xback to summary
public float x

The x coordinate.

yback to summary
public float y

The y coordinate.

zback to summary
public float z

The z coordinate.

Constructor Detail

Quat4fback to summary
public Quat4f()

Constructs and initializes a Quat4f to (0,0,0,0).

Quat4fback to summary
public Quat4f(float x, float y, float z, float w)

Constructs and initializes a Quat4f from the specified xyzw coordinates.

Parameters
x:float

the x coordinate

y:float

the y coordinate

z:float

the z coordinate

w:float

the w scalar component

Quat4fback to summary
public Quat4f(float[] q)

Constructs and initializes a Quat4f from the array of length 4.

Parameters
q:float[]

the array of length 4 containing xyzw in order

Quat4fback to summary
public Quat4f(Quat4f q1)

Constructs and initializes a Quat4f from the specified Quat4f.

Parameters
q1:Quat4f

the Quat4f containing the initialization x y z w data

Method Detail

normalizeback to summary
public final void normalize()

Normalizes the value of this quaternion in place.

scaleback to summary
public final void scale(float s)

Sets the value of this Quat4f to the scalar multiplication of the scale factor with this.

Parameters
s:float

the scalar value

setback to summary
public final void set(Matrix3f m1)

Sets the value of this quaternion to the rotational component of the passed matrix.

Parameters
m1:Matrix3f

the Matrix3f

setback to summary
public final void set(float[][] m1)

Sets the value of this quaternion to the rotational component of the passed float matrix.

Parameters
m1:float[][]

the float[3][3] matrix

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Returns a String that represents the value of this Quat4f.

Returns:String

a string representation of this Quat4f.

Annotations
@Override