Mapping between a Direct3D 9 Declaration and a Direct3D 8 Declaration (Direct3D 9)

This table maps members of a D3DVERTEXELEMENT9 declaration to a Direct3D 8 declaration.

Direct3D 9 UsageDirect3D 9 Usage indexDirect3D 8
D3DDECLUSAGE_POSITION0D3DVSDE_POSITION
D3DDECLUSAGE_POSITION1D3DVSDE_POSITION2
D3DDECLUSAGE_NORMAL0D3DVSDE_NORMAL
D3DDECLUSAGE_NORMAL1D3DVSDE_NORMAL2
D3DDECLUSAGE_BLENDWEIGHT0D3DVSDE_BLENDWEIGHT
D3DDECLUSAGE_BLENDINDICES0D3DVSDE_BLENDINDICES
D3DDECLUSAGE_PSIZE0D3DVSDE_PSIZE
D3DDECLUSAGE_COLOR0D3DVSDE_DIFFUSE
D3DDECLUSAGE_COLOR1D3DVSDE_SPECULAR
D3DDECLUSAGE_TEXCOORDnD3DVSDE_TEXCOORDn

 

When a declaration is used with hardware vertex processing on a Direct3D 7 driver, the Direct3D runtime converts it to a FVF with the following rules:

  • Only stream 0 should be used (evident from the MaxStreams cap).
  • The order of vertex elements should be the same as order of FVF bits.
  • Gaps in texture coordinates are not allowed.
  • Any vertex element not described the table cannot be converted into a valid FVF for all pre-DirectX 8 drivers and, hence, cannot be used on those drivers.
  • Only D3DDECLTYPE_FLOAT2 is allowed for vertex elements with D3DDECLUSAGE_TEXCOORD if device does not set either of the D3DPTEXTURECAPS_PROJECTED or D3DPTEXTURECAPS_CUBEMAP caps.

 

 

Community Additions

ADD
Show:
© 2014 Microsoft