xvimagesink: mark as NO_SHARE

We don't want to share the memory between buffers because that could
cause the memory of the bufferpool buffers to be copied and replaced
with other memory.

This is a hopefully a temporary fix until we can figure out how to share
properly.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=695203
This commit is contained in:
Wim Taymans 2013-03-05 16:34:35 +01:00
parent ce626fc3d8
commit b740edff06
2 changed files with 3 additions and 3 deletions

View file

@ -397,8 +397,8 @@ xvimage_memory_alloc (GstXvImageBufferPool * xvpool)
error_caught = FALSE;
XSetErrorHandler (handler);
gst_memory_init (GST_MEMORY_CAST (mem), 0, xvpool->allocator,
NULL, mem->size + align, align, offset, mem->size);
gst_memory_init (GST_MEMORY_CAST (mem), GST_MEMORY_FLAG_NO_SHARE,
xvpool->allocator, NULL, mem->size + align, align, offset, mem->size);
g_mutex_unlock (&xvimagesink->x_lock);

View file

@ -1849,7 +1849,7 @@ gst_xvimagesink_show_frame (GstVideoSink * vsink, GstBuffer * buf)
goto no_buffer;
GST_CAT_LOG_OBJECT (GST_CAT_PERFORMANCE, xvimagesink,
"slow copy into bufferpool buffer %p", to_put);
"slow copy buffer %p into bufferpool buffer %p", buf, to_put);
if (!gst_video_frame_map (&src, &xvimagesink->info, buf, GST_MAP_READ))
goto invalid_buffer;