Microsoft DirectX 8.0 (Visual Basic)

FVF Usage Settings for Destination Vertex Buffers

The Direct3DDevice8.ProcessVertices method requires specific settings for the Flexible Vertex Format Flags of the destination vertex buffer. The flexible vertex format (FVF) usage settings must be compatible with the current settings for vertex processing.

For fixed function vertex processing, ProcessVertices requires the following FVF settings.

In addition, the texture coordinate count must be set in the following manner.

Thus, for each texture stage, a new set of texture coordinates is generated if a texture is bound to that stage and any of the following conditions are true.

When Direct3D is generating texture coordinates, the application is required to perform the following actions.

  1. Use a destination vertex buffer with the appropriate FVF usage.
  2. Reprogram the D3DTSS_TEXCOORDINDEX of the texture stage according to the placement of the post -processed texture coordinates. Note that the reprogramming of the D3DTSS_TEXCOORDINDEX setting occurs when the processed vertex buffer is used in subsequent Direct3DDevice8.DrawPrimitive and Direct3DDevice8.DrawIndexedPrimitive calls.

Finally, texture coordinate dimensionality (D3DFVF_TEX0 through D3DFVF_TEX8) must be set in the following manner.

When ProcessVertices fails due to an incompatible destination vertex buffer FVF code, the expected code is printed to the debug output (debug builds only).