C# Class Ohana3DS_Transfigured.Ohana.AnimationUtils

ファイルを表示 Open project: Quibilia/Ohana3DS-Transfigured

Public Methods

Method Description
getKey ( RenderBase sourceFrame, float frame ) : float

Interpolates a Key Frame from a list of Key Frames.

getLeftFrame ( List keyFrames, float frame ) : RenderBase.OAnimationKeyFrame

Gets the rounded down frame relative to the given Key Frame.

getRightFrame ( List keyFrames, float frame ) : RenderBase.OAnimationKeyFrame

Gets the rounded up frame relative to the given Key Frame.

interpolateHermite ( List keyFrames, float frame ) : float

Interpolates a point between two Key Frames on a given Frame using Hermite Interpolation.

interpolateLinear ( RenderBase a, RenderBase b, float mu ) : RenderBase.OVector3

Interpolates a point between two vectors using Linear Interpolation.

interpolateLinear ( RenderBase a, RenderBase b, float mu ) : RenderBase.OVector4

Interpolates a point between two vectors using Linear Interpolation.

interpolateLinear ( List keyFrames, float frame ) : float

Interpolates a point between two Key Frames on a given Frame using Linear Interpolation.

interpolateLinear ( float a, float b, float mu ) : float

Interpolates a point between two points using Linear Interpolation.

interpolateStep ( List keyFrames, float frame ) : float

Gets the smaller point between two Key Frames. It doesn't actually interpolates anything, just returns the closest value.

Method Details

getKey() public static method

Interpolates a Key Frame from a list of Key Frames.
public static getKey ( RenderBase sourceFrame, float frame ) : float
sourceFrame RenderBase The list of key frames
frame float The frame that should be returned or interpolated from the list
return float

getLeftFrame() public static method

Gets the rounded down frame relative to the given Key Frame.
public static getLeftFrame ( List keyFrames, float frame ) : RenderBase.OAnimationKeyFrame
keyFrames List List with the Key Frames
frame float The frame number used as reference
return RenderBase.OAnimationKeyFrame

getRightFrame() public static method

Gets the rounded up frame relative to the given Key Frame.
public static getRightFrame ( List keyFrames, float frame ) : RenderBase.OAnimationKeyFrame
keyFrames List List with the Key Frames
frame float The frame number used as reference
return RenderBase.OAnimationKeyFrame

interpolateHermite() public static method

Interpolates a point between two Key Frames on a given Frame using Hermite Interpolation.
public static interpolateHermite ( List keyFrames, float frame ) : float
keyFrames List The list with all available Key Frames (Hermite format)
frame float The frame number that should be interpolated
return float

interpolateLinear() public static method

Interpolates a point between two vectors using Linear Interpolation.
public static interpolateLinear ( RenderBase a, RenderBase b, float mu ) : RenderBase.OVector3
a RenderBase First vector
b RenderBase Second vector
mu float Value between 0-1 of the interpolation amount
return RenderBase.OVector3

interpolateLinear() public static method

Interpolates a point between two vectors using Linear Interpolation.
public static interpolateLinear ( RenderBase a, RenderBase b, float mu ) : RenderBase.OVector4
a RenderBase First vector
b RenderBase Second vector
mu float Value between 0-1 of the interpolation amount
return RenderBase.OVector4

interpolateLinear() public static method

Interpolates a point between two Key Frames on a given Frame using Linear Interpolation.
public static interpolateLinear ( List keyFrames, float frame ) : float
keyFrames List The list with all available Key Frames (Linear format)
frame float The frame number that should be interpolated
return float

interpolateLinear() public static method

Interpolates a point between two points using Linear Interpolation.
public static interpolateLinear ( float a, float b, float mu ) : float
a float First point
b float Second point
mu float Value between 0-1 of the interpolation amount
return float

interpolateStep() public static method

Gets the smaller point between two Key Frames. It doesn't actually interpolates anything, just returns the closest value.
public static interpolateStep ( List keyFrames, float frame ) : float
keyFrames List The list with all available Key Frames (Linear format)
frame float The frame number that should be returned
return float