11.01.2014 Views

NVIDIA CUDA

NVIDIA CUDA

NVIDIA CUDA

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

208 Module Documentation<br />

• Textures which are not of a format which is 1, 2, or 4 channels of 8, 16, or 32-bit integer or floating-point data<br />

cannot be shared.<br />

• Surfaces of depth or stencil formats cannot be shared.<br />

If Direct3D interoperability is not initialized on this context, then <strong>CUDA</strong>_ERROR_INVALID_CONTEXT is returned.<br />

If pResource is of incorrect type (e.g. is a non-stand-alone IDirect3DSurface9) or is already registered,<br />

then <strong>CUDA</strong>_ERROR_INVALID_HANDLE is returned. If pResource cannot be registered then <strong>CUDA</strong>_ERROR_-<br />

UNKNOWN is returned.<br />

Parameters:<br />

pResource - Resource to register for <strong>CUDA</strong> access<br />

Flags - Flags for resource registration<br />

Returns:<br />

Note:<br />

<strong>CUDA</strong>_SUCCESS, <strong>CUDA</strong>_ERROR_DEINITIALIZED, <strong>CUDA</strong>_ERROR_NOT_INITIALIZED, <strong>CUDA</strong>_-<br />

ERROR_INVALID_CONTEXT, <strong>CUDA</strong>_ERROR_INVALID_VALUE, <strong>CUDA</strong>_ERROR_INVALID_HANDLE,<br />

<strong>CUDA</strong>_ERROR_OUT_OF_MEMORY, <strong>CUDA</strong>_ERROR_UNKNOWN<br />

See also:<br />

Note that this function may also return error codes from previous, asynchronous launches.<br />

cuGraphicsD3D9RegisterResource<br />

4.35.2.4 cuD3D9ResourceGetMappedArray (CUarray ∗ pArray, IDirect3DResource9 ∗ pResource, unsigned<br />

int Face, unsigned int Level)<br />

Deprecated<br />

This function is deprecated as of Cuda 3.0.<br />

Returns in ∗pArray an array through which the subresource of the mapped Direct3D resource pResource<br />

which corresponds to Face and Level may be accessed. The value set in pArray may change every time that<br />

pResource is mapped.<br />

If pResource is not registered then <strong>CUDA</strong>_ERROR_INVALID_HANDLE is returned. If pResource was not<br />

registered with usage flags CU_D3D9_REGISTER_FLAGS_ARRAY then <strong>CUDA</strong>_ERROR_INVALID_HANDLE is<br />

returned. If pResource is not mapped then <strong>CUDA</strong>_ERROR_NOT_MAPPED is returned.<br />

For usage requirements of Face and Level parameters, see cuD3D9ResourceGetMappedPointer().<br />

Parameters:<br />

pArray - Returned array corresponding to subresource<br />

pResource - Mapped resource to access<br />

Face - Face of resource to access<br />

Level - Level of resource to access<br />

Returns:<br />

<strong>CUDA</strong>_SUCCESS, <strong>CUDA</strong>_ERROR_DEINITIALIZED, <strong>CUDA</strong>_ERROR_NOT_INITIALIZED, <strong>CUDA</strong>_-<br />

ERROR_INVALID_CONTEXT, <strong>CUDA</strong>_ERROR_INVALID_VALUE, <strong>CUDA</strong>_ERROR_INVALID_HANDLE,<br />

<strong>CUDA</strong>_ERROR_NOT_MAPPED<br />

Generated for <strong>NVIDIA</strong> <strong>CUDA</strong> Library by Doxygen

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!