?/TD> |
Microsoft DirectX 9.0 |
Defines the primitives supported by Microsoft?Direct3D?
Syntax
typedef enum _D3DPRIMITIVETYPE { D3DPT_POINTLIST = 1, D3DPT_LINELIST = 2, D3DPT_LINESTRIP = 3, D3DPT_TRIANGLELIST = 4, D3DPT_TRIANGLESTRIP = 5, D3DPT_TRIANGLEFAN = 6, D3DPT_FORCE_DWORD = 0x7fffffff } D3DPRIMITIVETYPE;
Constants
- D3DPT_POINTLIST
Renders the vertices as a collection of isolated points. This value is unsupported for indexed primitives.
- D3DPT_LINELIST
Renders the vertices as a list of isolated straight line segments. Calls using this primitive type fail if the count is less than two or is odd.
- D3DPT_LINESTRIP
Renders the vertices as a single polyline. Calls using this primitive type fail if the count is less than two.
- D3DPT_TRIANGLELIST
Renders the specified vertices as a sequence of isolated triangles. Each group of three vertices defines a separate triangle.
Back-face culling is affected by the current winding-order render state.
- D3DPT_TRIANGLESTRIP
Renders the vertices as a triangle strip. The backface-culling flag is automatically flipped on even-numbered triangles.
- D3DPT_TRIANGLEFAN
Renders the vertices as a triangle fan.
- D3DPT_FORCE_DWORD
Forces this enumeration to compile to 32 bits in size. This value is not used.
Remarks
Using Triangle Strips or Triangle Fans is often more efficient than using triangle lists because fewer vertices are duplicated.
Enumerated Type Information
Header d3d9types.h Minimum operating systems Windows 98
See Also
IDirect3DDevice9::DrawIndexedPrimitive, IDirect3DDevice9::DrawIndexedPrimitiveUP, IDirect3DDevice9::DrawPrimitive, IDirect3DDevice9::DrawPrimitiveUP