From aff64af8ad8adf57b107d85083926f80e5291952 Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Sat, 24 May 2014 18:43:28 -0400 Subject: [PATCH] v4l2bufferpool: Fix USERPTR map flags We need to map READ only for output and write only for capture, we where doing the opposite. This fixing USERPTR with glimagesink https://bugzilla.gnome.org/show_bug.cgi?id=730698 --- sys/v4l2/gstv4l2bufferpool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/v4l2/gstv4l2bufferpool.c b/sys/v4l2/gstv4l2bufferpool.c index ea08558..ce8b994 100644 --- a/sys/v4l2/gstv4l2bufferpool.c +++ b/sys/v4l2/gstv4l2bufferpool.c @@ -194,7 +194,7 @@ gst_v4l2_buffer_pool_import_userptr (GstV4l2BufferPool * pool, if (!gst_v4l2_is_buffer_valid (dest, &group)) goto not_our_buffer; - if (!V4L2_TYPE_IS_OUTPUT (pool->obj->type)) + if (V4L2_TYPE_IS_OUTPUT (pool->obj->type)) flags = GST_MAP_READ; else flags = GST_MAP_WRITE; -- 2.7.4