Blt
Expand Minimize

SetRenderState routine

The SetRenderState function updates a render state.

Syntax


PFND3DDDI_SETRENDERSTATE SetRenderState;

__checkReturn HRESULT APIENTRY SetRenderState(
  _In_  HANDLE hDevice,
  _In_  const D3DDDIARG_RENDERSTATE *pData
)
{ ... }

Parameters

hDevice [in]

A handle to the display device (graphics context).

pData [in]

A pointer to a D3DDDIARG_RENDERSTATE structure that describes how to update the render state.

Return value

SetRenderState returns S_OK or an appropriate error result if the render state is not successfully updated.

Remarks

The Microsoft Direct3D runtime maps BeginScene and EndScene calls from applications to the user-mode display driver's SetRenderState function. When the runtime receives a BeginScene call, it sets the State member of the D3DDDIARG_RENDERSTATE structure that is pointed to by pData to D3DRENDERSTATE_SCENECAPTURE and the Value member of D3DDDIARG_RENDERSTATE to TRUE and then calls SetRenderState. When the runtime receives an EndScene call, it sets the State member to D3DRENDERSTATE_SCENECAPTURE and the Value member to FALSE and then calls SetRenderState. In between these calls to SetRenderState, the driver captures geometric data within a frame.

Requirements

Version

Available in Windows Vista and later versions of the Windows operating systems.

Header

D3dumddi.h (include D3dumddi.h)

See also

D3DDDIARG_RENDERSTATE
D3DDDI_DEVICEFUNCS

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft