10bit CUeglColorFormat in nvivafilter

I am running gstreamer pipeline to decode H265 stream using Jetson Orin’s hardware decoder. I need to grab frames and process them in CUDA. Best solution I found so far was to use nvivafilter, but seems nvivafilter only supports NV12 or RGBA CUeglColorFormat. Both of these are only 8-bit. My incoming content is 10bit, is there a way to access the 10bit buffer from CUDA?

This is my current pipeline:

/usr/bin/gst-launch-1.0 filesrc location=<mp4> ! \
  qtdemux ! queue ! h265parse ! nvv4l2decoder ! \
  nvivafilter cuda-process=true customer-lib-name="libnvsample_cudaprocess.so" ! \
  'video/x-raw(memory:NVMM), format=(string)RGBA' ! \
  fakesink -e

Hi,
It is not supported on Jetson Nano. 10-bit h265 stream will be decoded into 8-bit YUV420 on Jetson Nano.

I am using " Jetson AGX Orin Developer Kit", not Nano. Is there a way to access the 10bit buffer from CUDA?

Hi,
Please execute the command and share the prints for reference:

$ cat /etc/nv_tegra_release

This topic is in Jetson Nano category, so we get confused. Would like to confirm which platform and software version you are using.

Sorry, not sure how the category “Jetson Nano” is added, the device I use is Jetson AGX Orin Developer Kit:

$ cat /etc/nv_tegra_release
# R35 (release), REVISION: 2.1, GCID: 32413640, BOARD: t186ref, EABI: aarch64, DATE: Tue Jan 24 23:38:33 UTC 2023

Hi,
Please refer to the sample:
Error generated while running the code after connecting the camera - #15 by DaveYYY

It demonstrates:

GstBuffer → NvBufSurface → CUeglFrame → OpenCV

You can follow the function calls to get CUeglFrame and access the buffer through CUDA.

The pipeline will be like:

filesrc ! qtdemux ! queue ! h265parse ! nvv4l2decoder ! nvvidconv ! 'video/x-raw(memory:NVMM),format=P010_10LE' ! appsink

or

filesrc ! qtdemux ! queue ! h265parse ! nvv4l2decoder ! nvvidconv ! 'video/x-raw(memory:NVMM),format=I420_10LE' ! appsink

And you can access the buffer in appsink

Besides, the latest release is Jetpack 5.1.2(r35.4.1). It would be great if you can upgrade to latest version.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.