ID3DXRenderToSurface interface
The ID3DXRenderToSurface interface is used to generalize the process of rendering to surfaces.
Members
The ID3DXRenderToSurface interface inherits from the IUnknown interface. ID3DXRenderToSurface also has these types of members:
Methods
The ID3DXRenderToSurface interface has these methods.
Method | Description |
---|---|
BeginScene | Begins a scene. |
EndScene | Ends a scene. |
GetDesc | Retrieves the parameters of the render surface. |
GetDevice | Retrieves the Direct3D device associated with the render surface. |
OnLostDevice | Use this method to release all references to video memory resources and delete all stateblocks. This method should be called whenever a device is lost or before resetting a device. |
OnResetDevice | Use this method to re-acquire resources and save initial state. |
Remarks
Surfaces can be used in a variety of ways including render targets, off-screen rendering, or rendering to textures.
A surface can be configured using a separate viewport using the ID3DXRenderToSurface::BeginScene method, to provide a custom render view. If the surface is not a render target, a compatible render target is used, and the result is copied to the surface at the end of the scene.
The ID3DXRenderToSurface interface is obtained by calling the D3DXCreateRenderToSurface function.
The LPD3DXRENDERTOSURFACE type is defined as a pointer to the ID3DXRenderToSurface interface.
typedef interface ID3DXRenderToSurface ID3DXRenderToSurface;
typedef interface ID3DXRenderToSurface *LPD3DXRENDERTOSURFACE;
Requirements
Requirement | Value |
---|---|
Header |
|
Library |
|
See also