Surface Interfaces
A surface represents a linear area of display memory. A surface usually resides in the display memory of the display card, although surfaces can exist in system memory. Surface objects are contained within the IDirect3DSurface8 interface.
An IDirect3DSurface8 interface is obtained by calling one of the following methods:
- IDirect3DDevice8::CreateDepthStencilSurface
- IDirect3DDevice8::CreateImageSurface
- IDirect3DDevice8::CreateRenderTarget
- IDirect3DDevice8::GetBackBuffer
- IDirect3DDevice8::GetDepthStencilSurface
- IDirect3DDevice8::GetFrontBuffer
- IDirect3DDevice8::GetRenderTarget
- IDirect3DSwapChain8::GetBackBuffer
- IDirect3DTexture8::GetSurfaceLevel
The IDirect3DSurface8 interface enables you to indirectly access memory through the IDirect3DDevice8::CopyRects method. This method allows you to copy a rectangular region of pixels from one IDirect3DSurface8 interface to another IDirect3DSurface8 interface. The surface interface also has methods to directly access display memory. For example, you can use the IDirect3DSurface8::LockRect method to lock a rectangular region of display memory. It is important to call IDirect3DSurface8::UnlockRect after you are done working with the locked rectangular region on the surface.
See Also
Last updated on Thursday, April 08, 2004
© 1992-2003 Microsoft Corporation. All rights reserved.