UxrInterpolator.SmoothDampRotation Method

Smooths a rotation value using the last rotation, new rotation and a smooth value between [0.0, 1.0]. This tries to do something similar to SmoothDamp(Vector3, Vector3, Vector3, Single, Single) but for rotations.

Namespace: UltimateXR.Animation.Interpolation
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0

Syntax

C#

public static Quaternion SmoothDampRotation(
	Quaternion oldRot,
	Quaternion newRot,
	float smooth
)

Parameters

 

oldRot
Type: Quaternion
Old rotation
newRot
Type: Quaternion
New rotation
smooth
Type: System.Single
Smooth value [0.0, 1.0] where 0.0 is no smoothing and 1.0 is maximum smoothing

Return Value

Type: Quaternion
Smoothed rotation value

See Also

Reference

UxrInterpolator Class
UltimateXR.Animation.Interpolation Namespace