Class quat
Quaternion.
menori.ml.quat
Functions
quat.from_euler_angles (y, p, r) | from euler angles |
quat.from_angle_axis (angle, axis, a3, a4) | from angle axis |
quat.from_direction (forward, up) | from direction |
quat.dot (a, b) | dot |
quat.lerp (a, b, s) | lerp |
quat.slerp (a, b, s) | slerp |
quat.is_quat (a) | is quat |
Methods
quat:clone () | clone |
quat:set (x, y, z, w) | set |
quat:add (other) | add |
quat:sub (other) | sub |
quat:mul (other) | mul |
quat:multiply_vec3 (v3) | multiply vec3 |
quat:scale (s) | scale |
quat:pow (s) | pow |
quat:conjugate () | conjugate |
quat:inverse () | inverse |
quat:normalize () | normalize |
quat:reciprocal () | reciprocal |
quat:length () | length |
quat:length2 () | length2 |
quat:unpack (a) | unpack |
quat:is_zero () | is zero |
quat:is_real () | is real |
quat:is_imaginary () | is imaginary |
quat:to_angle_axis_unpack () | to angle axis unpack |
quat:to_angle_axis () | to angle axis |
quat:to_euler (order) | to euler angles |
Functions
- quat.from_euler_angles (y, p, r)
-
from euler angles
Parameters:
- y
- p
- r
- quat.from_angle_axis (angle, axis, a3, a4)
-
from angle axis
Parameters:
- angle
- axis
- a3
- a4
- quat.from_direction (forward, up)
-
from direction
Parameters:
- forward
- up
- quat.dot (a, b)
-
dot
Parameters:
- a
- b
- quat.lerp (a, b, s)
-
lerp
Parameters:
- a
- b
- s
- quat.slerp (a, b, s)
-
slerp
Parameters:
- a
- b
- s
- quat.is_quat (a)
-
is quat
Parameters:
- a
Methods
- quat:clone ()
- clone
- quat:set (x, y, z, w)
-
set
Parameters:
- x
- y
- z
- w
- quat:add (other)
-
add
Parameters:
- other
- quat:sub (other)
-
sub
Parameters:
- other
- quat:mul (other)
-
mul
Parameters:
- other
- quat:multiply_vec3 (v3)
-
multiply vec3
Parameters:
- v3
- quat:scale (s)
-
scale
Parameters:
- s
- quat:pow (s)
-
pow
Parameters:
- s
- quat:conjugate ()
- conjugate
- quat:inverse ()
- inverse
- quat:normalize ()
- normalize
- quat:reciprocal ()
- reciprocal
- quat:length ()
- length
- quat:length2 ()
- length2
- quat:unpack (a)
-
unpack
Parameters:
- a
- quat:is_zero ()
- is zero
- quat:is_real ()
- is real
- quat:is_imaginary ()
- is imaginary
- quat:to_angle_axis_unpack ()
- to angle axis unpack
- quat:to_angle_axis ()
- to angle axis
- quat:to_euler (order)
-
to euler angles
Parameters:
- order