Fail to mmap the capture_plane of decoder in MMAPI

Hi, I try to mmap the capture_plane of decoder, but it return error.

I have modifed “00_video_decode” to reproduce this issue.

ret = dec->capture_plane.setupPlane(V4L2_MEMORY_MMAP, min_dec_capture_buffers+ 5, true, false);

then it failed and print “Error in decoder capture plane setup”

Is there any advice?

Hi zcs, please share the purpose of the change.

Hi, DaneLLL

I want to map capture plane buffer of decoder to modify YUV data.

Please try new APIs in r28.1
NvBufferMemMap
NvBufferMemUnMap

Hi DaneLLL,

Thank you for your reply. I will try it.

What is the difference between NvBufferMemMap and mmap?

Not sure how mmap is implemented. NvBufferMemMap is new APIs to fix off-sync issues on r24.2.1

A relative topic:
https://devtalk.nvidia.com/default/topic/996666/jetson-tx1/msync-with-ms_sync-option-failure/post/5101903/#5101903