javax.vecmath
Class Vector3f
- Serializable
public class Vector3f
implements Serializable
A 3 element vector that is represented by single precision floating point
x,y,z coordinates. If this value represents a normal, then it should be
normalized.
specification 1.1, implementation $Revision: 1.9 $, $Date: 1999/10/05 07:03:50 $
Vector3f() - Constructs and initializes a Vector3f to (0,0,0).
|
Vector3f(float x, float y, float z) - Constructs and initializes a Vector3f from the specified xyz coordinates.
|
Vector3f(Tuple3d t1) - Constructs and initializes a Vector3f from the specified Tuple3d.
|
Vector3f(Tuple3f t1) - Constructs and initializes a Vector3f from the specified Tuple3f.
|
Vector3f(Vector3d v1) - Constructs and initializes a Vector3f from the specified Vector3d.
|
Vector3f(Vector3f v1) - Constructs and initializes a Vector3f from the specified Vector3f.
|
Vector3f(v[] ) - Constructs and initializes a Vector3f from the specified array of length 3.
|
float | angle(Vector3f v1) - Returns the angle in radians between this vector and
the vector parameter; the return value is constrained to the
range [0,PI].
|
void | cross(Vector3f v1, Vector3f v2) - Sets this vector to be the vector cross product of vectors v1 and v2.
|
float | dot(Vector3f v1) - Computes the dot product of the this vector and vector v1.
|
float | length() - Returns the length of this vector.
|
float | lengthSquared() - Returns the squared length of this vector.
|
void | normalize() - Normalizes this vector in place.
|
void | normalize(Vector3f v1) - Sets the value of this vector to the normalization of vector v1.
|
absolute , absolute , add , add , clamp , clamp , clampMax , clampMax , clampMin , clampMin , epsilonEquals , equals , get , get , hashCode , interpolate , interpolate , negate , negate , scale , scale , scaleAdd , scaleAdd , set , set , set , set , sub , sub , toString |
Vector3f
public Vector3f()
Constructs and initializes a Vector3f to (0,0,0).
Vector3f
public Vector3f(float x,
float y,
float z)
Constructs and initializes a Vector3f from the specified xyz coordinates.
x
- the x coordinatey
- the y coordinatez
- the z coordinate
Vector3f
public Vector3f(Tuple3d t1)
Constructs and initializes a Vector3f from the specified Tuple3d.
t1
- the Tuple3d containing the initialization x y z data
Vector3f
public Vector3f(Tuple3f t1)
Constructs and initializes a Vector3f from the specified Tuple3f.
t1
- the Tuple3f containing the initialization x y z data
Vector3f
public Vector3f(Vector3d v1)
Constructs and initializes a Vector3f from the specified Vector3d.
v1
- the Vector3d containing the initialization x y z data
Vector3f
public Vector3f(Vector3f v1)
Constructs and initializes a Vector3f from the specified Vector3f.
v1
- the Vector3f containing the initialization x y z data
Vector3f
public Vector3f(v[] )
Constructs and initializes a Vector3f from the specified array of length 3.
angle
public final float angle(Vector3f v1)
Returns the angle in radians between this vector and
the vector parameter; the return value is constrained to the
range [0,PI].
- the angle in radians in the range [0,PI]
cross
public final void cross(Vector3f v1,
Vector3f v2)
Sets this vector to be the vector cross product of vectors v1 and v2.
v1
- the first vectorv2
- the second vector
dot
public final float dot(Vector3f v1)
Computes the dot product of the this vector and vector v1.
length
public final float length()
Returns the length of this vector.
- the length of this vector
lengthSquared
public final float lengthSquared()
Returns the squared length of this vector.
- the squared length of this vector
normalize
public final void normalize()
Normalizes this vector in place.
normalize
public final void normalize(Vector3f v1)
Sets the value of this vector to the normalization of vector v1.
v1
- the un-normalized vector