UxrInterpolator.Interpolate Method (Vector4, Vector4, Single, Single, Single, UxrEasing, UxrLoopMode, Single, Boolean)
Interpolates between two Vector4 values
Namespace: UltimateXR.Animation.Interpolation
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0
Syntax
C#
public static Vector4 Interpolate(
Vector4 startValue,
Vector4 endValue,
float duration,
float delay,
float time,
UxrEasing easing,
UxrLoopMode loopMode = UxrLoopMode.None,
float loopedDuration = -1f,
bool delayUsingEndValue = false
)
Parameters
- startValue
- Type: Vector4
The start value - endValue
- Type: Vector4
The end value - duration
- Type: System.Single
The duration of the interpolation. If there is looping (loopMode != LoopMode.None) then it will specify the duration of a single loop - delay
- Type: System.Single
The delay duration before the interpolation starts - time
- Type: System.Single
The time value. This value will be clamped between [delay, delay + duration] or if there is looping (loopMode != LoopMode.None) then it will be clamped between [delay, delay + loopedDuration]. In this case duration will specify the duration of the loop - easing
- Type: UltimateXR.Animation.Interpolation.UxrEasing
The interpolation method to use. See @Easing - loopMode (Optional)
- Type: UltimateXR.Animation.Interpolation.UxrLoopMode
Which looping mode to use. See @LoopMode - loopedDuration (Optional)
- Type: System.Single
If loopMode is not LoopMode.None then loopedDuration will specify the duration of the interpolation including all the loops. A negative value will make it loop forever. - delayUsingEndValue (Optional)
- Type: System.Boolean
Tells whether to use the interpolation end value during the delay, if there is a delay specified. By default it’s false, which means the interpolation start value is used during the delay.
Return Value
Type: Vector4
Interpolated Vector4 value
See Also
Reference
UxrInterpolator Class
Interpolate Overload
UltimateXR.Animation.Interpolation Namespace