Provided by: nvidia-cuda-dev_9.1.85-3ubuntu1_amd64
NAME
VDPAU Interoperability - Functions cudaError_t cudaGraphicsVDPAURegisterOutputSurface (struct cudaGraphicsResource **resource, VdpOutputSurface vdpSurface, unsigned int flags) Register a VdpOutputSurface object. cudaError_t cudaGraphicsVDPAURegisterVideoSurface (struct cudaGraphicsResource **resource, VdpVideoSurface vdpSurface, unsigned int flags) Register a VdpVideoSurface object. cudaError_t cudaVDPAUGetDevice (int *device, VdpDevice vdpDevice, VdpGetProcAddress *vdpGetProcAddress) Gets the CUDA device associated with a VdpDevice. cudaError_t cudaVDPAUSetVDPAUDevice (int device, VdpDevice vdpDevice, VdpGetProcAddress *vdpGetProcAddress) Sets a CUDA device to use VDPAU interoperability.
Detailed Description
This section describes the VDPAU interoperability functions of the CUDA runtime application programming interface.
Function Documentation
cudaError_t cudaGraphicsVDPAURegisterOutputSurface (struct cudaGraphicsResource ** resource, VdpOutputSurface vdpSurface, unsigned int flags) Registers the VdpOutputSurface specified by vdpSurface for access by CUDA. A handle to the registered object is returned as resource. The surface's intended usage is specified using flags, as follows: • cudaGraphicsMapFlagsNone: Specifies no hints about how this resource will be used. It is therefore assumed that this resource will be read from and written to by CUDA. This is the default value. • cudaGraphicsMapFlagsReadOnly: Specifies that CUDA will not write to this resource. • cudaGraphicsMapFlagsWriteDiscard: Specifies that CUDA will not read from this resource and will write over the entire contents of the resource, so none of the data previously stored in the resource will be preserved. Parameters: resource - Pointer to the returned object handle vdpSurface - VDPAU object to be registered flags - Map flags Returns: cudaSuccess, cudaErrorInvalidDevice, cudaErrorInvalidValue, cudaErrorInvalidResourceHandle, cudaErrorUnknown Note: Note that this function may also return error codes from previous, asynchronous launches. See also: cudaVDPAUSetVDPAUDevice, cudaGraphicsUnregisterResource, cudaGraphicsSubResourceGetMappedArray, cuGraphicsVDPAURegisterOutputSurface cudaError_t cudaGraphicsVDPAURegisterVideoSurface (struct cudaGraphicsResource ** resource, VdpVideoSurface vdpSurface, unsigned int flags) Registers the VdpVideoSurface specified by vdpSurface for access by CUDA. A handle to the registered object is returned as resource. The surface's intended usage is specified using flags, as follows: • cudaGraphicsMapFlagsNone: Specifies no hints about how this resource will be used. It is therefore assumed that this resource will be read from and written to by CUDA. This is the default value. • cudaGraphicsMapFlagsReadOnly: Specifies that CUDA will not write to this resource. • cudaGraphicsMapFlagsWriteDiscard: Specifies that CUDA will not read from this resource and will write over the entire contents of the resource, so none of the data previously stored in the resource will be preserved. Parameters: resource - Pointer to the returned object handle vdpSurface - VDPAU object to be registered flags - Map flags Returns: cudaSuccess, cudaErrorInvalidDevice, cudaErrorInvalidValue, cudaErrorInvalidResourceHandle, cudaErrorUnknown Note: Note that this function may also return error codes from previous, asynchronous launches. See also: cudaVDPAUSetVDPAUDevice, cudaGraphicsUnregisterResource, cudaGraphicsSubResourceGetMappedArray, cuGraphicsVDPAURegisterVideoSurface cudaError_t cudaVDPAUGetDevice (int * device, VdpDevice vdpDevice, VdpGetProcAddress * vdpGetProcAddress) Returns the CUDA device associated with a VdpDevice, if applicable. Parameters: device - Returns the device associated with vdpDevice, or -1 if the device associated with vdpDevice is not a compute device. vdpDevice - A VdpDevice handle vdpGetProcAddress - VDPAU's VdpGetProcAddress function pointer Returns: cudaSuccess Note: Note that this function may also return error codes from previous, asynchronous launches. See also: cudaVDPAUSetVDPAUDevice, cuVDPAUGetDevice cudaError_t cudaVDPAUSetVDPAUDevice (int device, VdpDevice vdpDevice, VdpGetProcAddress * vdpGetProcAddress) Records vdpDevice as the VdpDevice for VDPAU interoperability with the CUDA device device and sets device as the current device for the calling host thread. If device has already been initialized then this call will fail with the error cudaErrorSetOnActiveProcess. In this case it is necessary to reset device using cudaDeviceReset() before VDPAU interoperability on device may be enabled. Parameters: device - Device to use for VDPAU interoperability vdpDevice - The VdpDevice to interoperate with vdpGetProcAddress - VDPAU's VdpGetProcAddress function pointer Returns: cudaSuccess, cudaErrorInvalidDevice, cudaErrorSetOnActiveProcess Note: Note that this function may also return error codes from previous, asynchronous launches. See also: cudaGraphicsVDPAURegisterVideoSurface, cudaGraphicsVDPAURegisterOutputSurface, cudaDeviceReset
Author
Generated automatically by Doxygen from the source code.