12.07.2015 Views

NVIDIA CUDA

NVIDIA CUDA

NVIDIA CUDA

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

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

188 Module Documentation• ID3D10Texture1D: No restrictions.• ID3D10Texture2D: No restrictions.• ID3D10Texture3D: No restrictions.The flags argument specifies the mechanism through which <strong>CUDA</strong> will access the Direct3D resource. The followingvalues are allowed.• CU_D3D10_REGISTER_FLAGS_NONE: Specifies that <strong>CUDA</strong> will access this resource through aCUdeviceptr. The pointer, size, and (for textures), pitch for each subresource of this allocationmay be queried through cuD3D10ResourceGetMappedPointer(), cuD3D10ResourceGetMappedSize(), andcuD3D10ResourceGetMappedPitch() respectively. This option is valid for all resource types.• CU_D3D10_REGISTER_FLAGS_ARRAY: Specifies that <strong>CUDA</strong> will access this resource through a CUarrayqueried on a sub-resource basis through cuD3D10ResourceGetMappedArray(). This option is only valid forresources of type ID3D10Texture1D, ID3D10Texture2D, and ID3D10Texture3D.Not all Direct3D resources of the above types may be used for interoperability with <strong>CUDA</strong>. The following are somelimitations.• The primary rendertarget may not be registered with <strong>CUDA</strong>.• Resources allocated as shared may not be registered with <strong>CUDA</strong>.• Textures which are not of a format which is 1, 2, or 4 channels of 8, 16, or 32-bit integer or floating-point datacannot be shared.• Surfaces of depth or stencil formats cannot be shared.If Direct3D interoperability is not initialized on this context then <strong>CUDA</strong>_ERROR_INVALID_CONTEXT is returned.If pResource is of incorrect type or is already registered, then <strong>CUDA</strong>_ERROR_INVALID_HANDLE is returned.If pResource cannot be registered, then <strong>CUDA</strong>_ERROR_UNKNOWN is returned.Parameters:pResource - Resource to registerflags - Parameters for resource registrationReturns:Note:<strong>CUDA</strong>_SUCCESS, <strong>CUDA</strong>_ERROR_DEINITIALIZED, <strong>CUDA</strong>_ERROR_NOT_INITIALIZED, <strong>CUDA</strong>_-ERROR_INVALID_CONTEXT, <strong>CUDA</strong>_ERROR_INVALID_VALUE, <strong>CUDA</strong>_ERROR_INVALID_HANDLE,<strong>CUDA</strong>_ERROR_OUT_OF_MEMORY, <strong>CUDA</strong>_ERROR_UNKNOWNSee also:Note that this function may also return error codes from previous, asynchronous launches.cuD3D10CtxCreate, cuD3D10GetDevice, cuD3D10MapResources, cuD3D10ResourceGetMappedArray,cuD3D10ResourceGetMappedPitch, cuD3D10ResourceGetMappedPointer, cuD3D10ResourceGetMappedSize,cuD3D10ResourceGetSurfaceDimensions, cuD3D10ResourceSetMapFlags, cuD3D10UnmapResources,cuD3D10UnregisterResourceGenerated on Wed Apr 1 16:11:42 2009 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!