Direct3D Mobile Surface Interfaces
A version of this page is also available for
4/8/2010
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 IDirect3DMobileSurface interface.
An IDirect3DMobileSurface interface is obtained by calling one of the following methods:
- IDirect3DMobileDevice::CreateDepthStencilSurface
- IDirect3DMobileDevice::CreateImageSurface
- IDirect3DMobileDevice::CreateRenderTarget
- IDirect3DMobileDevice::GetBackBuffer
- IDirect3DMobileDevice::GetDepthStencilSurface
- IDirect3DMobileDevice::GetFrontBuffer
- IDirect3DMobileDevice::GetRenderTarget
- IDirect3DMobileSwapChain::GetBackBuffer
- IDirect3DMobileTexture::GetSurfaceLevel
The IDirect3DMobileSurface interface enables you to indirectly access memory through the IDirect3DMobileDevice::CopyRects method. This method allows you to copy a rectangular region of pixels from one IDirect3DMobileSurface interface to another IDirect3DMobileSurface interface. The surface interface also has methods to directly access display memory. For example, you can use the IDirect3DMobileSurface::LockRect method to lock a rectangular region of display memory. It is important to call IDirect3DMobileSurface::UnlockRect after you are done working with the locked rectangular region on the surface.