diff options
author | Nicolas Dufresne <nicolas.dufresne@collabora.com> | 2015-07-27 16:58:22 -0400 |
---|---|---|
committer | Nicolas Dufresne <nicolas.dufresne@collabora.co.uk> | 2015-07-28 08:54:29 -0400 |
commit | adbd9d3c05b40241bca389466c8b1e0589342c8c (patch) | |
tree | bdf9d911a4cc93d89850f0d7b4998b359ba17847 /gst-libs/gst/gl/gstglmemory.c | |
parent | eb4d3c352ad088467b0ba0aa4097fbda4e34b0f4 (diff) | |
download | gstreamer-plugins-bad-adbd9d3c05b40241bca389466c8b1e0589342c8c.tar.gz |
glupload: Keep input frame mapped as long as needed
When performing a raw upload, we need to keep the raw data mapped as
long as needed.
https://bugzilla.gnome.org/show_bug.cgi?id=752937
Diffstat (limited to 'gst-libs/gst/gl/gstglmemory.c')
-rw-r--r-- | gst-libs/gst/gl/gstglmemory.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/gst-libs/gst/gl/gstglmemory.c b/gst-libs/gst/gl/gstglmemory.c index e1818fbc8..5d3f73a05 100644 --- a/gst-libs/gst/gl/gstglmemory.c +++ b/gst-libs/gst/gl/gstglmemory.c @@ -1508,22 +1508,26 @@ gst_gl_memory_setup_buffer (GstGLContext * context, * @valign: a #GstVideoInfo * @data: a list of per plane data pointers * @textures: (transfer out): a list of #GstGLMemory + * @user_data: user data for the destroy function + * @notify: A function called each time a memory is freed * * Wraps per plane data pointer in @data into the corresponding entry in - * @textures based on @info and padding from @valign. + * @textures based on @info and padding from @valign. Note that the @notify + * will be called as many time as there is planes. * * Returns: whether the memory's were sucessfully created. */ gboolean gst_gl_memory_setup_wrapped (GstGLContext * context, GstVideoInfo * info, GstVideoAlignment * valign, gpointer data[GST_VIDEO_MAX_PLANES], - GstGLMemory * textures[GST_VIDEO_MAX_PLANES]) + GstGLMemory * textures[GST_VIDEO_MAX_PLANES], gpointer user_data, + GDestroyNotify notify) { gint i; for (i = 0; i < GST_VIDEO_INFO_N_PLANES (info); i++) { textures[i] = (GstGLMemory *) gst_gl_memory_wrapped (context, info, i, - valign, data[i], NULL, NULL); + valign, data[i], user_data, notify); } return TRUE; |