CUresult cuD3D10CtxCreate ( CUcontext pCtx,
CUdevice pCudaDevice,
unsigned int  Flags,
ID3D10Device *  pD3DDevice 
)

Creates a new CUDA context, enables interoperability for that context with the Direct3D device pD3DDevice, and associates the created CUDA context with the calling thread. The created CUcontext will be returned in *pCtx. Direct3D resources from this device may be registered and mapped through the lifetime of this CUDA context. If pCudaDevice is non-NULL then the CUdevice on which this CUDA context was created will be returned in *pCudaDevice.

On success, this call will increase the internal reference count on pD3DDevice. This reference count will be decremented upon destruction of this context through cuCtxDestroy(). This context will cease to function if pD3DDevice is destroyed or encounters an error.

Parameters:
pCtx - Returned newly created CUDA context
pCudaDevice - Returned pointer to the device on which the context was created
Flags - Context creation flags (see cuCtxCreate() for details)
pD3DDevice - Direct3D device to create interoperability context with
Returns:
CUDA_SUCCESS, CUDA_ERROR_DEINITIALIZED, CUDA_ERROR_NOT_INITIALIZED, CUDA_ERROR_INVALID_VALUE, CUDA_ERROR_OUT_OF_MEMORY, CUDA_ERROR_UNKNOWN
Note:
Note that this function may also return error codes from previous, asynchronous launches.
See also:
cuD3D10GetDevice, cuGraphicsD3D10RegisterResource


Generated by Doxygen for NVIDIA CUDA Library  NVIDIA