Angular and linear velocities history tracker.
This helper allows to accumulate and smooth the velocities over multiple frames.
Computes the angular velocity based on the current history.
The output angular velocity.
vec3 The out parameter.
out
This method isn't a simple getter and will perform computations, Only use once per frame or after the object is rotated.
Resets the history tracker.
The object that was tracked.
This method needs a target because it resets the history based on the position of the target.
Update the history with the given object.
The target object to update from.
The delta time.
Update the history with the given XR pose.
The XR pose.
The object to get the velocity from, in case the XR pose doesn't expose any.
Use this when available, because the velocities from the XR Pose are more accurate.
Computes the linear velocity based on the current history.
The output velocity.
The out parameter.
This method isn't a simple getter and will perform computations, Only use this once per frame or after the object is moved.
Angular and linear velocities history tracker.
This helper allows to accumulate and smooth the velocities over multiple frames.