TransitionType Enumeration (Microsoft.DirectX.Direct3D)
Defines the transition style between values of a mesh animation.
Definition
Visual Basic Public Enum TransitionType C# public enum TransitionType C++ public enum class TransitionType JScript public enum TransitionType
Members
Member Value Description EaseInEaseOut 1 Ease-in, ease-out spline transition between values. Linear 0 Linear transition between values.
Remarks
The calculation for the ramp from ease-in to ease-out is calculated as follows.
Q(t) = 2(x - y)t3 + 3(y - x)t2 + x.
where the ramp is a function Q(t) with the following properties:
- Q(t) is a cubic spline.
- Q(t) interpolates between x and y as t ranges from 0 to 1.
- Q(t) is horizontal when t = 0 and t = 1.
Mathematically, this translates into:
Q(t) = At3 + Bt2 + Ct + D (and therefore, Q'(t) = 3At2 + 2Bt + C)
Q(0) = x (2a)
Q(1) = y (2b)
Q'(0) = 0 (3a)
Q'(1) = 0 (3b)
Solving for A, B, C, D:
D = x (from 2a)
C = 0 (from 3a)
3A + 2B = 0 (from 3b)
A + B = y - x (from 2b and D = x)
Therefore:
A = 2(x - y), B = 3(y - x), C = 0, D = x.
Enumeration Information
Namespace Microsoft.DirectX.Direct3D Assembly Microsoft.DirectX.Direct3DX (microsoft.directx.direct3dx.dll) Strong Name Microsoft.DirectX.Direct3DX, Version=1.0.900.0, Culture=neutral, PublicKeyToken=d3231b57b74a1492
See Also