?/TD>
Microsoft DirectX 9.0

D3DXTRANSITIONTYPE Enumerated Type


Flags used to specify the transition style between values of a mesh animation.

Syntax

typedef enum _D3DXTRANSITIONTYPE {
    D3DXTRANSITION_LINEAR = 0x000,
    D3DXTRANSITION_EASEINEASEOUT = 0x001,
    D3DXTRANSITION_FORCE_DWORD = 0x7fffffff
} D3DXTRANSITIONTYPE;

Constants

D3DXTRANSITION_LINEAR

Linear transition between values.

D3DXTRANSITION_EASEINEASEOUT

Ease-in, ease-out spline transition between values.

D3DXTRANSITION_FORCE_DWORD

Forces this enumeration to compile to 32 bits in size.

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:

Mathematically, this translates into:

Q(t) = At3 + Bt2 + Ct + D (and therefore, Q'(t) = 3At2 + 2Bt + C) 
a) Q(0) = x 
b) Q(1) = y

a) Q'(0) = 0 
b) Q'(1) = 0

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.

Enumerated Type Information

Headerd3dx9anim.h
Minimum operating systems Windows 98


© 2002 Microsoft Corporation. All rights reserved.