NvMediaImage Surfaces to CUDA Consumer on dGPU (nvm_egldgpu)

The NvMedia dGPU sample application, nvm_egldgpu, demonstrates how to use NvMediaEglstream APIs to post NvMediaImage surfaces to dGPU, which can be processed by CUDA APIs running on dGPU.

The application supports a single image producer and a single CUDA consumer. It can run with a single process for producer and consumer or with two different processes. The image producer must be on Tegra and the CUDA consumer must be on iGPU or dGPU. Single-process and cross-process operation work for both combinations.

The image producer reads image data from an input file and posts it to the CUDA consumer through EGLStream. The image producer accepts YUV420 or RAW formats as input.

In FIFO mode, if the input to the image producer bit matches the output of the CUDA consumer, then the test is successful. In mailbox mode, the number of frames acquired by the consumer depends on the speed at which the producer and consumer are running. You cannot compare input and output files directly in mailbox mode.