All Packages Class Hierarchy This Package Previous Next Index
Class java.vecmath.Vector3f
java.lang.Object
|
+----java.vecmath.Tuple3f
|
+----java.vecmath.Vector3f
- public class Vector3f
- extends Tuple3f
A 3 element vector that is represented by single precision floating point
x,y,z coordinates.
-
Vector3f()
- Constructs and initializes a Vector3f to (0,0,0).
-
Vector3f(float, float, float)
- Constructs and initializes a Vector3f from the specified xyz coordinates.
-
Vector3f(float[])
- Constructs and initializes a Vector3f from the array of length 3.
-
Vector3f(Vector3d)
- Constructs and initializes a Vector3f from the specified Vector3d.
-
Vector3f(Vector3f)
- Constructs and initializes a Vector3f from the specified Vector3f.
-
angle(Vector3f)
-
Returns the angle in radians between this vector and the vector
parameter; the return value is constrained to the range [0,PI].
-
cross(Vector3f, Vector3f)
- Sets this vector to be the vector cross product of vectors v1 and v2.
-
dot(Vector3f)
- Computes the dot product of this vector and vector v1.
-
length()
- Returns the length of this vector.
-
lengthSquared()
- Returns the squared length of this vector.
-
normalize()
- Normalizes this vector in place.
-
normalize(Vector3f)
- Sets the value of this vector to the normalization of vector v1.
Vector3f
public Vector3f(float x,
float y,
float z)
- Constructs and initializes a Vector3f from the specified xyz coordinates.
- Parameters:
- x - the x coordinate
- y - the y coordinate
- z - the z coordinate
Vector3f
public Vector3f(float v[])
- Constructs and initializes a Vector3f from the array of length 3.
- Parameters:
- v - the array of length 3 containing xyz in order
Vector3f
public Vector3f(Vector3f v1)
- Constructs and initializes a Vector3f from the specified Vector3f.
- Parameters:
- v1 - the Vector3f containing the initialization x y z data
Vector3f
public Vector3f(Vector3d v1)
- Constructs and initializes a Vector3f from the specified Vector3d.
- Parameters:
- v1 - the Vector3d containing the initialization x y z data
Vector3f
public Vector3f()
- Constructs and initializes a Vector3f to (0,0,0).
lengthSquared
public final float lengthSquared()
- Returns the squared length of this vector.
- Returns:
- the squared length of this vector
length
public final float length()
- Returns the length of this vector.
- Returns:
- the length of this vector
cross
public final void cross(Vector3f v1,
Vector3f v2)
- Sets this vector to be the vector cross product of vectors v1 and v2.
- Parameters:
- v1 - the first vector
- v2 - the second vector
dot
public final float dot(Vector3f v1)
- Computes the dot product of this vector and vector v1.
- Parameters:
- v1 - the other vector
- Returns:
- the dot product of this vector and v1
normalize
public final void normalize(Vector3f v1)
- Sets the value of this vector to the normalization of vector v1.
- Parameters:
- v1 - the un-normalized vector
normalize
public final void normalize()
- Normalizes this vector in place.
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].
- Parameters:
- v1 - The other vector
- Returns:
- The angle in radians in the range [0,PI]
All Packages Class Hierarchy This Package Previous Next Index