Immediate Mode Changes for DirectX 6.0
DirectX 6.0 is backward compatible with all prior versions of DirectX, and offers several features that improve performance, increase ease-of-use, and exploit new hardware features:
Performance enhancements:
- Support for buffers to contain vertex data, called "vertex buffers," acting as staging points for more efficient transformation and rendering of vertices. Vertex buffers can be optimized to make it possible to transform vertex data more efficiently, and transformed vertices in a vertex buffer can be reused (rather than transforming them multiple times). The IDirect3DDevice3 interface introduces the IDirect3DDevice3::DrawPrimitiveVB and IDirect3DDevice3::DrawIndexedPrimitiveVB to render vertices from a vertex buffer.
- Applications can increase the performance of Direct3D by setting the DDSCL_FPUSETUP DirectDraw cooperative level. This cooperative level eliminates overhead incurred when Direct3D is forced to check and reset the FPU precision mode for each rendering cycle. For more information, see DirectDraw Cooperative Levels and FPU Precision.
- Direct3D now includes a reference driver that, although not intended for shipping applications, produces extremely accurate output for testing and demonstration purposes.
Ease-of-use improvements
- Automatically managed texture surfaces. See Automatic Texture Management for details.
- More flexible ways to declare vertices in memory. Applications are no longer required to use only predefined vertex types, and can even include per-vertex color components for lit vertices. For more information, see Vertex Formats.
- Support for discrete or interleaved arrays of vertex component data. For additional discussion of strided vertices, see Strided Vertex Format.
Support for cutting-edge hardware features:
- Direct3D Immediate Mode supports hardware that can perform single-pass multiple texture blending. Direct3D exposes the concepts of texture stages, blending operations, and blending arguments in the new IDirect3DDevice3 interface, through the IDirect3DDevice3::SetTextureStageState method. For more information, see Multiple Texture Blending.
- You can use the new texture blending features of Direct3D to perform bump mapping. The bump-mapping model, offered through the multiple texture blending interface, utilizes special bump-map surfaces to perturb the texture coordinates applied to environment maps.
- Support for an alternative form of depth buffering that uses eye-space Z in the depth buffer, often called "w-buffering." For more information, see Depth Buffers.
- Support for stencil buffers (also known as "stencil planes"). For more information, see Stencil Buffers.
DirectX 6.0 uses the same object model that was utilized in DirectX 5.0. (This is a different object model than was used in DirectX 3, however), however the programming approaches offered by legacy interfaces are still supported in DirectX 6.0.