summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Waters <matthew@centricular.com>2017-01-10 19:58:48 +1100
committerMatthew Waters <matthew@centricular.com>2017-01-10 19:58:48 +1100
commita1f2da88bffbb85baa566612d314c50e89c92055 (patch)
tree0dfa18ef8b35fbea63c549c9d4d8112fde06be78
parente4345d7be45e8baafc93362e2a50761803a966f6 (diff)
downloadgstreamer-plugins-bad-a1f2da88bffbb85baa566612d314c50e89c92055.tar.gz
gl: add necessary get_type() functions for allocation params structures
All using the existing GstGLAllocationParams infrastructure
-rw-r--r--docs/libs/gst-plugins-bad-libs.types7
-rw-r--r--gst-libs/gst/gl/gstglbasememory.c2
-rw-r--r--gst-libs/gst/gl/gstglbasememory.h4
-rw-r--r--gst-libs/gst/gl/gstglbuffer.c5
-rw-r--r--gst-libs/gst/gl/gstglbuffer.h4
-rw-r--r--gst-libs/gst/gl/gstglmemory.c4
-rw-r--r--gst-libs/gst/gl/gstglmemory.h5
-rw-r--r--gst-libs/gst/gl/gstglrenderbuffer.c5
-rw-r--r--gst-libs/gst/gl/gstglrenderbuffer.h3
9 files changed, 37 insertions, 2 deletions
diff --git a/docs/libs/gst-plugins-bad-libs.types b/docs/libs/gst-plugins-bad-libs.types
index ff31ee9dc..6d5a82b35 100644
--- a/docs/libs/gst-plugins-bad-libs.types
+++ b/docs/libs/gst-plugins-bad-libs.types
@@ -39,11 +39,14 @@ gst_mpegts_stream_type_get_type
gst_insert_bin_get_type
-gst_gl_buffer_allocator_get_type
-gst_gl_base_memory_allocator_get_type
gst_gl_allocation_params_get_type
+gst_gl_base_memory_allocator_get_type
+gst_gl_buffer_allocation_params_get_type
+gst_gl_buffer_allocator_get_type
+gst_gl_video_allocation_params_get_type
gst_gl_memory_allocator_get_type
gst_gl_memory_pbo_allocator_get_type
+gst_gl_renderbuffer_allocation_params_get_type
gst_gl_renderbuffer_allocator_get_type
gst_gl_base_filter_get_type
gst_gl_buffer_pool_get_type
diff --git a/gst-libs/gst/gl/gstglbasememory.c b/gst-libs/gst/gl/gstglbasememory.c
index 4c663f8dc..0a01dfeaf 100644
--- a/gst-libs/gst/gl/gstglbasememory.c
+++ b/gst-libs/gst/gl/gstglbasememory.c
@@ -46,6 +46,8 @@
GST_DEBUG_CATEGORY_STATIC (GST_CAT_GL_BASE_MEMORY);
#define GST_CAT_DEFUALT GST_CAT_GL_BASE_MEMORY
+GST_DEFINE_MINI_OBJECT_TYPE (GstGLBaseMemory, gst_gl_base_memory);
+
GQuark
gst_gl_base_memory_error_quark (void)
{
diff --git a/gst-libs/gst/gl/gstglbasememory.h b/gst-libs/gst/gl/gstglbasememory.h
index 622eef110..fea124aa2 100644
--- a/gst-libs/gst/gl/gstglbasememory.h
+++ b/gst-libs/gst/gl/gstglbasememory.h
@@ -29,6 +29,10 @@
G_BEGIN_DECLS
+#define GST_TYPE_GL_BASE_MEMORY (gst_gl_base_memory_get_type())
+GST_EXPORT
+GType gst_gl_base_memory_get_type(void);
+
#define GST_TYPE_GL_BASE_MEMORY_ALLOCATOR (gst_gl_base_memory_allocator_get_type())
GST_EXPORT
GType gst_gl_base_memory_allocator_get_type(void);
diff --git a/gst-libs/gst/gl/gstglbuffer.c b/gst-libs/gst/gl/gstglbuffer.c
index d50fd6d0b..ba67e2d62 100644
--- a/gst-libs/gst/gl/gstglbuffer.c
+++ b/gst-libs/gst/gl/gstglbuffer.c
@@ -345,6 +345,11 @@ _gst_gl_buffer_allocation_params_free_data (GstGLBufferAllocationParams *
gst_gl_allocation_params_free_data (&params->parent);
}
+G_DEFINE_BOXED_TYPE (GstGLBufferAllocationParams,
+ gst_gl_buffer_allocation_params,
+ (GBoxedCopyFunc) gst_gl_allocation_params_copy,
+ (GBoxedFreeFunc) gst_gl_allocation_params_free);
+
/**
* gst_gl_buffer_allocation_params_new:
* @context: a #GstGLContext
diff --git a/gst-libs/gst/gl/gstglbuffer.h b/gst-libs/gst/gl/gstglbuffer.h
index f139f2d17..01deb8a8c 100644
--- a/gst-libs/gst/gl/gstglbuffer.h
+++ b/gst-libs/gst/gl/gstglbuffer.h
@@ -60,6 +60,10 @@ struct _GstGLBuffer
typedef struct _GstGLBufferAllocationParams GstGLBufferAllocationParams;
+#define GST_TYPE_GL_BUFFER_ALLOCATION_PARAMS (gst_gl_buffer_allocation_params_get_type())
+GST_EXPORT
+GType gst_gl_buffer_allocation_params_get_type (void);
+
#define GST_GL_ALLOCATION_PARAMS_ALLOC_FLAG_BUFFER (1 << 4)
/**
diff --git a/gst-libs/gst/gl/gstglmemory.c b/gst-libs/gst/gl/gstglmemory.c
index 31e102e32..428b46a05 100644
--- a/gst-libs/gst/gl/gstglmemory.c
+++ b/gst-libs/gst/gl/gstglmemory.c
@@ -1043,6 +1043,10 @@ gst_is_gl_memory (GstMemory * mem)
GST_TYPE_GL_MEMORY_ALLOCATOR);
}
+G_DEFINE_BOXED_TYPE (GstGLVideoAllocationParams, gst_gl_video_allocation_params,
+ (GBoxedCopyFunc) gst_gl_allocation_params_copy,
+ (GBoxedFreeFunc) gst_gl_allocation_params_free);
+
static void
_gst_gl_video_allocation_params_set_video_alignment (GstGLVideoAllocationParams
* params, GstVideoAlignment * valign)
diff --git a/gst-libs/gst/gl/gstglmemory.h b/gst-libs/gst/gl/gstglmemory.h
index a7f488c27..9a55b9df5 100644
--- a/gst-libs/gst/gl/gstglmemory.h
+++ b/gst-libs/gst/gl/gstglmemory.h
@@ -83,6 +83,11 @@ struct _GstGLMemory
gpointer _padding[GST_PADDING];
};
+
+#define GST_TYPE_GL_VIDEO_ALLOCATION_PARAMS (gst_gl_video_allocation_params_get_type())
+GST_EXPORT
+GType gst_gl_video_allocation_params_get_type (void);
+
typedef struct _GstGLVideoAllocationParams GstGLVideoAllocationParams;
#define GST_GL_ALLOCATION_PARAMS_ALLOC_FLAG_VIDEO (1 << 3)
diff --git a/gst-libs/gst/gl/gstglrenderbuffer.c b/gst-libs/gst/gl/gstglrenderbuffer.c
index f21ef54a4..aca17c050 100644
--- a/gst-libs/gst/gl/gstglrenderbuffer.c
+++ b/gst-libs/gst/gl/gstglrenderbuffer.c
@@ -334,6 +334,11 @@ gst_is_gl_renderbuffer (GstMemory * mem)
GST_TYPE_GL_RENDERBUFFER_ALLOCATOR);
}
+G_DEFINE_BOXED_TYPE (GstGLRenderbufferAllocationParams,
+ gst_gl_renderbuffer_allocation_params,
+ (GBoxedCopyFunc) gst_gl_allocation_params_copy,
+ (GBoxedFreeFunc) gst_gl_allocation_params_free);
+
static void
_gst_gl_rb_alloc_params_free_data (GstGLRenderbufferAllocationParams * params)
{
diff --git a/gst-libs/gst/gl/gstglrenderbuffer.h b/gst-libs/gst/gl/gstglrenderbuffer.h
index 5a9a1c07b..b624120ca 100644
--- a/gst-libs/gst/gl/gstglrenderbuffer.h
+++ b/gst-libs/gst/gl/gstglrenderbuffer.h
@@ -102,6 +102,9 @@ struct _GstGLRenderbufferAllocatorClass
#include <gst/gl/gstglbasememory.h>
+GType gst_gl_renderbuffer_allocation_params_get_type (void);
+#define GST_TYPE_RENDERBUFFER_ALLOCATION_PARAMS (gst_gl_renderbuffer_allocation_params_get_type)
+
typedef struct
{
GstGLAllocationParams parent;