Name
cgD3D10GetDevice - retrieves the current D3D10 device associated with a context
Synopsis
#include <Cg/cgD3D10.h>
ID3D10Device * cgD3D10GetDevice( CGcontext context );
Parameters
- context
-
The context from which to get the current device.
Return Values
Returns the current D3D10 device associated with context.
Description
cgD3D10GetDevice retrieves the current D3D10 device associated with context.
Note that the returned device pointer may be NULL.
Examples
ID3D10Device* curDevice = cgD3D10GetDevice(ctx);
Errors
CG_INVALID_CONTEXT_HANDLE_ERROR is generated if context is not a valid context.
History
cgD3D10GetDevice was introduced in Cg 2.1.
See Also
cgD3D10SetDevice
|