(no subject)

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

(no subject)

Harms Hannes
Hi,

I have tied to use VAAPI + appsink  with zero copy via DMABuf / mmap.

Therefore I used the following pipeline:

application/x-rtp, encoding-name=JPEG,payload=26 ! rtpjpegdepay !
vaapijpegdec ! capsfilter caps=video/x-raw(memory:DMABuf),format=I420
! appsink name=sink

Code form the appsink:

GstMemory* mem = gst_buffer_peek_memory(buffer, 0);
int fd = gst_dmabuf_memory_get_fd(mem);
void* map_data =  mmap(NULL,size,PROT_READ |
PROT_WRITE,MAP_SHARED,fd,0);

However mmap fails with Permission Denied, because the buffer is not
writable.

I tried again with:

void* map_data =  mmap(NULL,size,PROT_READ,MAP_SHARED,fd,0);

However the mapped data contains only zeros.

What am I missing?

Hardware is a Intel Atom E3950. Gstreamer 1.14.1

I also tried to to use VASurface,
but it is still unclear to me how to access data of a VASurface within
a appsink.

Many thanks
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel