ImageDev

CudaContext

Contains information on a CUDA context.

This class allows defining the execution context for CUDA functions. For more information, refer to the CUDA documentation.

Syntax

Method Description
Ptr New( int cudaDeviceId = 0, const bool initStream = true ) Constructor returning a new CUDA Context.
  • cudaDeviceId: Device ID of an NVIDIA card.
  • initStream: Indicates if the CUDA stream should be initialized or set to null.
int cudaDeviceId() const Gets the device ID.
void setCudaDeviceId( int newCudaDeviceId ) Sets the device ID.
  • newCudaDeviceId: Device ID of an NVIDIA card.
void* cudaStream() const Gets the CUDA stream.
void setCudaStream( void* newCudaStream ) Sets the CUDA stream.
  • newCudaStream: New CUDA stream.