javax.vecmath
Class Vector4d
- Serializable
public class Vector4d
implements Serializable
A 4 element vector that is represented by double precision floating point
x,y,z,w coordinates.
specification 1.1, implementation $Revision: 1.9 $, $Date: 1999/10/05 07:03:50 $
Vector4d() - Constructs and initializes a Vector4d to (0,0,0,0).
|
Vector4d(double x, double y, double z, double w) - Constructs and initializes a Vector4d from the specified xyzw coordinates.
|
Vector4d(Tuple3d t1) - Constructs and initializes a Vector4d from the specified Tuple3d.
|
Vector4d(Tuple4d t1) - Constructs and initializes a Vector4d from the specified Tuple4d.
|
Vector4d(Tuple4f t1) - Constructs and initializes a Vector4d from the specified Tuple4f.
|
Vector4d(Vector4d v1) - Constructs and initializes a Vector4d from the specified Vector4d.
|
Vector4d(Vector4f v1) - Constructs and initializes a Vector4d from the specified Vector4d.
|
Vector4d(v[] ) - Constructs and initializes a Vector4d from the specified array of length 4.
|
double | angle(Vector4d v1) - Returns the (4-space) angle in radians between this vector and
the vector parameter; the return value is constrained to the
range [0,PI].
|
double | dot(Vector4d v1) - Computes the dot product of the this vector and vector v1.
|
double | length() - Returns the length of this vector.
|
double | lengthSquared() - Returns the squared length of this vector.
|
void | normalize() - Normalizes this vector in place.
|
void | normalize(Vector4d v1) - Sets the value of this vector to the normalization of vector v1.
|
void | set(Tuple3d t1) - Sets the x,y,z components of this point to the corresponding
components of tuple t1.
|
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 |
Vector4d
public Vector4d()
Constructs and initializes a Vector4d to (0,0,0,0).
Vector4d
public Vector4d(double x,
double y,
double z,
double w)
Constructs and initializes a Vector4d from the specified xyzw coordinates.
x
- the x coordinatey
- the y coordinatez
- the z coordinatew
- the w coordinate
Vector4d
public Vector4d(Tuple3d t1)
Constructs and initializes a Vector4d from the specified Tuple3d.
The x,y,z components of this point are set to the corresponding
components
of tuple t1. The w component of this point is set to 0.
t1
- the tuple to be copied
Vector4d
public Vector4d(Tuple4d t1)
Constructs and initializes a Vector4d from the specified Tuple4d.
t1
- the Tuple4d containing the initialization x y z w data
Vector4d
public Vector4d(Tuple4f t1)
Constructs and initializes a Vector4d from the specified Tuple4f.
t1
- the Tuple4f containing the initialization x y z w data
Vector4d
public Vector4d(Vector4d v1)
Constructs and initializes a Vector4d from the specified Vector4d.
v1
- the Vector4d containing the initialization x y z w data
Vector4d
public Vector4d(Vector4f v1)
Constructs and initializes a Vector4d from the specified Vector4d.
v1
- the Vector4d containing the initialization x y z w data
Vector4d
public Vector4d(v[] )
Constructs and initializes a Vector4d from the specified array of length 4.
angle
public final double angle(Vector4d v1)
Returns the (4-space) 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]
dot
public final double dot(Vector4d v1)
Computes the dot product of the this vector and vector v1.
- the dot product of this vector and vector v1
length
public final double length()
Returns the length of this vector.
- the length of this vector
lengthSquared
public final double 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(Vector4d v1)
Sets the value of this vector to the normalization of vector v1.
v1
- the un-normalized vector
set
public final void set(Tuple3d t1)
Sets the x,y,z components of this point to the corresponding
components of tuple t1. The w component of this point is set to 1.
t1
- the tuple to be copied