- This function is deprecated as of CUDA 3.0.
the pitch and Z-slice pitch of the subresource of the mapped Direct3D resource
, which corresponds to
. The values set in
may change every time that
The pitch and Z-slice pitch values may be used to compute the location of a sample on a surface as follows.
For a 2D surface, the byte offset of the sample at position x, y from the base pointer of the surface is:
y * pitch + (bytes per pixel) * x
For a 3D surface, the byte offset of the sample at position x, y, z from the base pointer of the surface is:
z* slicePitch + y * pitch + (bytes per pixel) * x
pPitchSlice are optional and may be set to NULL.
pResource is not of type ID3D10Texture1D, ID3D10Texture2D, or ID3D10Texture3D, or if
pResource has not been registered for use with CUDA, then cudaErrorInvalidResourceHandle is returned. If
pResource was not registered with usage flags cudaD3D10RegisterFlagsNone, then cudaErrorInvalidResourceHandle is returned. If
pResource is not mapped for access by CUDA then cudaErrorUnknown is returned.
For usage requirements of the
subResource parameter see cudaD3D10ResourceGetMappedPointer().
|pPitch ||- Returned pitch of subresource |
|pPitchSlice ||- Returned Z-slice pitch of subresource |
|pResource ||- Mapped resource to access |
|subResource ||- Subresource of pResource to access|
- cudaSuccess, cudaErrorInvalidValue, cudaErrorInvalidResourceHandle, cudaErrorUnknown
- Note that this function may also return error codes from previous, asynchronous launches.
- See also: