public class MathUtils
extends java.lang.Object
Constructor and Description |
---|
MathUtils() |
Modifier and Type | Method and Description |
---|---|
static Quaternion |
exp(Quaternion q,
Quaternion store) |
static Quaternion |
log(Quaternion q,
Quaternion store) |
static float |
raySegmentShortestDistance(Ray ray,
Vector3f segStart,
Vector3f segEnd,
Camera camera)
Returns the shortest distance between a Ray and a segment.
|
static Quaternion |
slerp(Quaternion q1,
Quaternion q2,
float t,
Quaternion store) |
static Quaternion |
slerpNoInvert(Quaternion q1,
Quaternion q2,
float t,
Quaternion store) |
static Quaternion |
squad(Quaternion q0,
Quaternion q1,
Quaternion q2,
Quaternion q3,
Quaternion a,
Quaternion b,
float t,
Quaternion store) |
public static Quaternion log(Quaternion q, Quaternion store)
public static Quaternion exp(Quaternion q, Quaternion store)
public static Quaternion slerpNoInvert(Quaternion q1, Quaternion q2, float t, Quaternion store)
public static Quaternion slerp(Quaternion q1, Quaternion q2, float t, Quaternion store)
public static Quaternion squad(Quaternion q0, Quaternion q1, Quaternion q2, Quaternion q3, Quaternion a, Quaternion b, float t, Quaternion store)
public static float raySegmentShortestDistance(Ray ray, Vector3f segStart, Vector3f segEnd, Camera camera)
ray
- The raysegStart
- The start position of the segment in world spacesegEnd
- The end position of the segment in world spacecamera
- The renderer camera if the distance is required in screen space. Null if the distance is required in world space