public class VecFloat
extends Object
Modifier and Type | Field and Description |
---|---|
float |
x |
float |
y |
float |
z |
static VecFloat |
ZERO |
Modifier and Type | Method and Description |
---|---|
VecFloat |
add(VecFloat v)
Add
|
float |
dot(VecFloat v)
Scalar product
|
float |
length()
Length
|
float |
lengthSq()
length * length
|
VecFloat |
mul(float s)
Multiply with a float (scale)
|
VecFloat |
neg()
Negate (multiply with -1)
|
VecFloat |
normalized()
Get a vector in the same direction but with length 1
|
VecFloat |
sub(VecFloat v)
Subtract
|
String |
toString() |
static VecFloat |
xyz(float x,
float y,
float z)
Create
|
public static final VecFloat ZERO
public final float x
public final float y
public final float z
public static VecFloat xyz(float x, float y, float z)
public VecFloat mul(float s)
public VecFloat neg()
public float dot(VecFloat v)
public VecFloat normalized()
public float length()
public float lengthSq()
public final String toString()
toString
in class Object