NvBufSurfaceFromFd() - cannot get a surface in the cuda camera capture example

I’m going through jetson multimedia example 12 - (camera v4l cuda one)
and if I try NvBufSurfaceFromFd() to get a Surface for either render buffer or the jpegdec’s returned fd -
I don’t get back a surface pointer. The return result is 0, so it doesn’t technically fail.

Is there a reason for this? Both of these buffers seem to have the SurfaceArray memory type,
and inspecting them with NvBufferGetParamsEx() works fine.

I get why jpegdec would possibly return some opaque memory handle that’s not directly accessible via a Surface.
But the render buffer is explicitly allocated as a SurfaceArray via NvBufferCreateEx().

On Jetpack 4 releases, NvbufSurface APIs are used in DeepStream SDK. For jetson_multimedia_api, please use NvBuffer APIs listed in nvbuf_utils.h

NvBufSurfaceFromFd() is not supported in the use-case.

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