Show / Hide Table of Contents

Class Lerp

provides different LerpFunctions that can be used in a channel. A Lerp Function represents a linear interpolation between 2 points in a timeline.

Inheritance
System.Object
Lerp
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Fusee.Xirkit
Assembly: Fusee.Xirkit.dll
Syntax
public static class Lerp

Methods

DoubleLerp(Double, Double, Single, Single)

Lerp Function for Doubles.

Declaration
public static double DoubleLerp(double val1, double val2, float time1, float time2)
Parameters
Type Name Description
System.Double val1
System.Double val2
System.Single time1
System.Single time2
Returns
Type Description
System.Double

Float2Lerp(float2, float2, Single, Single)

Lerp Function for Float2.

Declaration
public static float2 Float2Lerp(float2 val1, float2 val2, float time1, float time2)
Parameters
Type Name Description
float2 val1
float2 val2
System.Single time1
System.Single time2
Returns
Type Description
float2

Float3Lerp(float3, float3, Single, Single)

Lerp Function for float3 values. Linearly interpolates the three components independently.

Declaration
public static float3 Float3Lerp(float3 val1, float3 val2, float time1, float time2)
Parameters
Type Name Description
float3 val1
float3 val2
System.Single time1
System.Single time2
Returns
Type Description
float3

Float3QuaternionSlerp(float3, float3, Single, Single)

Slerp Function for float3 using quaternion interpolation. Useful if the given float3 values contain euler angles in Pitch(x)/Yaw(y)/Roll(z) order. The euler angle set returned by this method is on the shortest spherical path between the two parameter euler angle sets. Note that using linear interpolation Float3Lerp(float3, float3, Single, Single) of angle values will NOT yield in a path lying on a great circle between the two parameters. Instead, using linear interpolation, the interpolated values will describe a curve called loxodrome which spirals around the poles (due to gimbal lock).

Declaration
public static float3 Float3QuaternionSlerp(float3 val1, float3 val2, float time1, float time2)
Parameters
Type Name Description
float3 val1
float3 val2
System.Single time1
System.Single time2
Returns
Type Description
float3

Float4Lerp(float4, float4, Single, Single)

Lerp Function for Float4s.

Declaration
public static float4 Float4Lerp(float4 val1, float4 val2, float time1, float time2)
Parameters
Type Name Description
float4 val1
float4 val2
System.Single time1
System.Single time2
Returns
Type Description
float4

FloatLerp(Single, Single, Single, Single)

Lerp Function for Float.

Declaration
public static float FloatLerp(float val1, float val2, float time1, float time2)
Parameters
Type Name Description
System.Single val1
System.Single val2
System.Single time1
System.Single time2
Returns
Type Description
System.Single

IntLerp(Int32, Int32, Single, Single)

Lerp Function for Int.

Declaration
public static int IntLerp(int val1, int val2, float time1, float time2)
Parameters
Type Name Description
System.Int32 val1
System.Int32 val2
System.Single time1
System.Single time2
Returns
Type Description
System.Int32
Generated by DocFX
GitHub Repo
Back to top