summaryrefslogtreecommitdiff
path: root/gst/gstcompat.h
diff options
context:
space:
mode:
authorWim Taymans <wim.taymans@collabora.co.uk>2011-06-10 13:40:57 +0200
committerWim Taymans <wim.taymans@collabora.co.uk>2011-06-10 13:49:23 +0200
commitb27ee30a35bb159f4d534fdd17dccc856e21904d (patch)
tree23c77fe2b7394614e0131e06de17577bc8a3039a /gst/gstcompat.h
parent30b3e90117a9f01981e8d707bd4963796d622af0 (diff)
downloadgstreamer-b27ee30a35bb159f4d534fdd17dccc856e21904d.tar.gz
buffer: make new _buffer_allocate method
Make a new method to allocate a buffer + memory that takes the allocator and the alignment as parameters. Provide a macro for the old method but prefer to use the new method to encourage plugins to negotiate the allocator properly.
Diffstat (limited to 'gst/gstcompat.h')
-rw-r--r--gst/gstcompat.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/gst/gstcompat.h b/gst/gstcompat.h
index 8d0c457f7d..cba5fc23f4 100644
--- a/gst/gstcompat.h
+++ b/gst/gstcompat.h
@@ -49,6 +49,9 @@ G_BEGIN_DECLS
//#define gst_buffer_create_sub(b,o,s) gst_buffer_copy_region(b,GST_BUFFER_COPY_ALL,o,s)
+#define gst_buffer_new_and_alloc(s) gst_buffer_new_allocate(NULL, s, 0)
+
+
#ifndef GST_DISABLE_DEPRECATED
#endif /* not GST_DISABLE_DEPRECATED */