plugins: integrate GstVaapiVideoBuffer from libgstvaapi.
authorGwenole Beauchesne <gwenole.beauchesne@intel.com>
Thu, 21 Mar 2013 16:06:43 +0000 (17:06 +0100)
committerGwenole Beauchesne <gwenole.beauchesne@intel.com>
Thu, 21 Mar 2013 17:16:14 +0000 (18:16 +0100)
Move GstVaapiVideoBuffer from core libgstvaapi decoding library to the
actual plugin elements. That's only useful there.

docs/reference/libs/libs-sections.txt
docs/reference/libs/libs.core.types
gst-libs/gst/vaapi/Makefile.am
gst-libs/gst/vaapi/gstvaapivideobuffer.h [deleted file]
gst/vaapi/Makefile.am
gst/vaapi/gstvaapidownload.h
gst/vaapi/gstvaapipluginbuffer.c
gst/vaapi/gstvaapipostproc.h
gst/vaapi/gstvaapivideobuffer.c [moved from gst-libs/gst/vaapi/gstvaapivideobuffer.c with 62% similarity]
gst/vaapi/gstvaapivideobuffer.h [new file with mode: 0644]
gst/vaapi/gstvaapivideoconverter_glx.h

index 11c742f..71e1ab9 100644 (file)
@@ -172,23 +172,6 @@ GST_VAAPI_IMAGE_POOL_GET_CLASS
 </SECTION>
 
 <SECTION>
-<FILE>gstvaapivideobuffer</FILE>
-<TITLE>GstVaapiVideoBuffer</TITLE>
-GstVaapiVideoBuffer
-GstVaapiVideoBufferClass
-gst_vaapi_video_buffer_new
-gst_vaapi_video_buffer_get_meta
-<SUBSECTION Standard>
-GST_VAAPI_VIDEO_BUFFER
-GST_VAAPI_IS_VIDEO_BUFFER
-GST_VAAPI_TYPE_VIDEO_BUFFER
-gst_vaapi_video_buffer_get_type
-GST_VAAPI_VIDEO_BUFFER_CLASS
-GST_VAAPI_IS_VIDEO_BUFFER_CLASS
-GST_VAAPI_VIDEO_BUFFER_GET_CLASS
-</SECTION>
-
-<SECTION>
 <FILE>gstvaapivideometa</FILE>
 <TITLE>GstVaapiVideoMeta</TITLE>
 gst_vaapi_video_meta_new
index b4ce7da..97954cf 100644 (file)
@@ -7,6 +7,5 @@ gst_vaapi_object_get_type
 gst_vaapi_subpicture_get_type
 gst_vaapi_surface_get_type
 gst_vaapi_surface_pool_get_type
-gst_vaapi_video_buffer_get_type
 gst_vaapi_video_pool_get_type
 gst_vaapi_window_get_type
index 68bb260..90ec07b 100644 (file)
@@ -68,7 +68,6 @@ libgstvaapi_source_c =                                \
        gstvaapisurfaceproxy.c                  \
        gstvaapiutils.c                         \
        gstvaapivalue.c                         \
-       gstvaapivideobuffer.c                   \
        gstvaapivideometa.c                     \
        gstvaapivideopool.c                     \
        gstvaapiwindow.c                        \
@@ -95,7 +94,6 @@ libgstvaapi_source_h =                                \
        gstvaapisurfaceproxy.h                  \
        gstvaapitypes.h                         \
        gstvaapivalue.h                         \
-       gstvaapivideobuffer.h                   \
        gstvaapivideometa.h                     \
        gstvaapivideopool.h                     \
        gstvaapiwindow.h                        \
diff --git a/gst-libs/gst/vaapi/gstvaapivideobuffer.h b/gst-libs/gst/vaapi/gstvaapivideobuffer.h
deleted file mode 100644 (file)
index adc88d0..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- *  gstvaapivideobuffer.h - Gstreamer/VA video buffer
- *
- *  Copyright (C) 2010-2011 Splitted-Desktop Systems
- *  Copyright (C) 2011-2013 Intel Corporation
- *
- *  This library is free software; you can redistribute it and/or
- *  modify it under the terms of the GNU Lesser General Public License
- *  as published by the Free Software Foundation; either version 2.1
- *  of the License, or (at your option) any later version.
- *
- *  This library is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- *  Lesser General Public License for more details.
- *
- *  You should have received a copy of the GNU Lesser General Public
- *  License along with this library; if not, write to the Free
- *  Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- *  Boston, MA 02110-1301 USA
- */
-
-#ifndef GST_VAAPI_VIDEO_BUFFER_H
-#define GST_VAAPI_VIDEO_BUFFER_H
-
-#include <gst/video/gstsurfacebuffer.h>
-#include <gst/vaapi/gstvaapivideometa.h>
-
-G_BEGIN_DECLS
-
-#define GST_VAAPI_TYPE_VIDEO_BUFFER \
-    (gst_vaapi_video_buffer_get_type())
-
-#define GST_VAAPI_VIDEO_BUFFER(obj)                             \
-    (G_TYPE_CHECK_INSTANCE_CAST((obj),                          \
-                                GST_VAAPI_TYPE_VIDEO_BUFFER,    \
-                                GstVaapiVideoBuffer))
-
-#define GST_VAAPI_VIDEO_BUFFER_CLASS(klass)                     \
-    (G_TYPE_CHECK_CLASS_CAST((klass),                           \
-                             GST_VAAPI_TYPE_VIDEO_BUFFER,       \
-                             GstVaapiVideoBufferClass))
-
-#define GST_VAAPI_IS_VIDEO_BUFFER(obj) \
-    (G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_VAAPI_TYPE_VIDEO_BUFFER))
-
-#define GST_VAAPI_IS_VIDEO_BUFFER_CLASS(klass) \
-    (G_TYPE_CHECK_CLASS_TYPE((klass), GST_VAAPI_TYPE_VIDEO_BUFFER))
-
-#define GST_VAAPI_VIDEO_BUFFER_GET_CLASS(obj)                   \
-    (G_TYPE_INSTANCE_GET_CLASS((obj),                           \
-                               GST_VAAPI_TYPE_VIDEO_BUFFER,     \
-                               GstVaapiVideoBufferClass))
-
-typedef struct _GstVaapiVideoBuffer             GstVaapiVideoBuffer;
-typedef struct _GstVaapiVideoBufferClass        GstVaapiVideoBufferClass;
-
-/**
- * GstVaapiVideoBuffer:
- *
- * A #GstBuffer holding video objects (#GstVaapiSurface and #GstVaapiImage).
- */
-struct _GstVaapiVideoBuffer {
-    /*< private >*/
-    GstSurfaceBuffer parent_instance;
-
-    GstVaapiVideoMeta *meta;
-};
-
-/**
- * GstVaapiVideoBufferClass:
- *
- * A #GstBuffer holding video objects
- */
-struct _GstVaapiVideoBufferClass {
-    /*< private >*/
-    GstSurfaceBufferClass parent_class;
-};
-
-GType
-gst_vaapi_video_buffer_get_type(void) G_GNUC_CONST;
-
-GstBuffer *
-gst_vaapi_video_buffer_new(GstVaapiVideoMeta *meta);
-
-GstVaapiVideoMeta *
-gst_vaapi_video_buffer_get_meta(GstVaapiVideoBuffer *buffer);
-
-G_END_DECLS
-
-#endif /* GST_VAAPI_VIDEO_BUFFER_H */
index 67b95fb..f12a43e 100644 (file)
@@ -39,6 +39,7 @@ libgstvaapi_source_c = \
        gstvaapisink.c          \
        gstvaapiupload.c        \
        gstvaapiuploader.c      \
+       gstvaapivideobuffer.c   \
        $(NULL)
 
 libgstvaapi_source_h = \
@@ -50,6 +51,7 @@ libgstvaapi_source_h = \
        gstvaapisink.h          \
        gstvaapiupload.h        \
        gstvaapiuploader.h      \
+       gstvaapivideobuffer.h   \
        $(NULL)
 
 if USE_GLX
index 7a594c4..28b58e7 100644 (file)
@@ -28,7 +28,6 @@
 #include <gst/vaapi/gstvaapisurface.h>
 #include <gst/vaapi/gstvaapiimagepool.h>
 #include <gst/vaapi/gstvaapisurfacepool.h>
-#include <gst/vaapi/gstvaapivideobuffer.h>
 
 G_BEGIN_DECLS
 
index 766978f..e24676e 100644 (file)
 
 #include "gst/vaapi/sysdeps.h"
 #include <gst/vaapi/gstvaapivideometa.h>
-#include <gst/vaapi/gstvaapivideobuffer.h>
 #if USE_GLX
 # include "gstvaapivideoconverter_glx.h"
 #endif
 #include "gstvaapipluginbuffer.h"
+#include "gstvaapivideobuffer.h"
 
 static GFunc
 get_surface_converter(GstVaapiDisplay *display)
index 4ad4f70..e983a31 100644 (file)
@@ -26,7 +26,6 @@
 #include <gst/vaapi/gstvaapidisplay.h>
 #include <gst/vaapi/gstvaapisurface.h>
 #include <gst/vaapi/gstvaapisurfacepool.h>
-#include <gst/vaapi/gstvaapivideobuffer.h>
 
 G_BEGIN_DECLS
 
similarity index 62%
rename from gst-libs/gst/vaapi/gstvaapivideobuffer.c
rename to gst/vaapi/gstvaapivideobuffer.c
index afb173c..f5945ed 100644 (file)
@@ -1,5 +1,5 @@
 /*
- *  gstvaapivideobuffer.c - Gst VA video buffer
+ *  gstvaapivideobuffer.c - Gstreamer/VA video buffer
  *
  *  Copyright (C) 2010-2011 Splitted-Desktop Systems
  *  Copyright (C) 2011-2013 Intel Corporation
  * @short_description: VA video buffer for GStreamer
  */
 
-#include "sysdeps.h"
+#include "gst/vaapi/sysdeps.h"
+#include <gst/video/gstsurfacebuffer.h>
 #include "gstvaapivideobuffer.h"
 
-#define DEBUG 1
-#include "gstvaapidebug.h"
+#define GST_VAAPI_TYPE_VIDEO_BUFFER \
+    (gst_vaapi_video_buffer_get_type())
+
+#define GST_VAAPI_VIDEO_BUFFER(obj)             \
+    (G_TYPE_CHECK_INSTANCE_CAST((obj),          \
+        GST_VAAPI_TYPE_VIDEO_BUFFER,            \
+        GstVaapiVideoBuffer))
+
+#define GST_VAAPI_VIDEO_BUFFER_CLASS(klass)     \
+    (G_TYPE_CHECK_CLASS_CAST((klass),           \
+        GST_VAAPI_TYPE_VIDEO_BUFFER,            \
+        GstVaapiVideoBufferClass))
+
+#define GST_VAAPI_IS_VIDEO_BUFFER(obj) \
+    (G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_VAAPI_TYPE_VIDEO_BUFFER))
+
+#define GST_VAAPI_IS_VIDEO_BUFFER_CLASS(klass) \
+    (G_TYPE_CHECK_CLASS_TYPE((klass), GST_VAAPI_TYPE_VIDEO_BUFFER))
+
+#define GST_VAAPI_VIDEO_BUFFER_GET_CLASS(obj)   \
+    (G_TYPE_INSTANCE_GET_CLASS((obj),           \
+        GST_VAAPI_TYPE_VIDEO_BUFFER,            \
+        GstVaapiVideoBufferClass))
+
+typedef struct _GstVaapiVideoBufferClass        GstVaapiVideoBufferClass;
+
+/**
+ * GstVaapiVideoBuffer:
+ *
+ * A #GstBuffer holding video objects (#GstVaapiSurface and #GstVaapiImage).
+ */
+struct _GstVaapiVideoBuffer {
+    /*< private >*/
+    GstSurfaceBuffer parent_instance;
+
+    GstVaapiVideoMeta *meta;
+};
+
+/**
+ * GstVaapiVideoBufferClass:
+ *
+ * A #GstBuffer holding video objects
+ */
+struct _GstVaapiVideoBufferClass {
+    /*< private >*/
+    GstSurfaceBufferClass parent_class;
+};
+
+GType
+gst_vaapi_video_buffer_get_type(void) G_GNUC_CONST;
 
 G_DEFINE_TYPE(GstVaapiVideoBuffer,
               gst_vaapi_video_buffer,
@@ -65,14 +114,6 @@ gst_vaapi_video_buffer_init(GstVaapiVideoBuffer *buffer)
 {
 }
 
-/**
- * gst_vaapi_video_buffer_new:
- * @meta: a #GstVaapiVideoMeta
- *
- * Creates a #GstBuffer that holds video @meta information.
- *
- * Return value: the newly allocated #GstBuffer, or %NULL or error
- */
 GstBuffer *
 gst_vaapi_video_buffer_new(GstVaapiVideoMeta *meta)
 {
@@ -88,15 +129,6 @@ gst_vaapi_video_buffer_new(GstVaapiVideoMeta *meta)
     return buffer;
 }
 
-/**
- * gst_vaapi_video_buffer_get_meta:
- * @buffer: a #GstVaapiVideoBuffer
- *
- * Returns the #GstVaapiVideoMeta associated to this @buffer.
- *
- * Return value: the #GstVaapiVideoMeta bound to the @buffer, or %NULL
- *   if none was found
- */
 GstVaapiVideoMeta *
 gst_vaapi_video_buffer_get_meta(GstVaapiVideoBuffer *buffer)
 {
diff --git a/gst/vaapi/gstvaapivideobuffer.h b/gst/vaapi/gstvaapivideobuffer.h
new file mode 100644 (file)
index 0000000..52d6eb7
--- /dev/null
@@ -0,0 +1,42 @@
+/*
+ *  gstvaapivideobuffer.h - Gstreamer/VA video buffer
+ *
+ *  Copyright (C) 2010-2011 Splitted-Desktop Systems
+ *  Copyright (C) 2011-2013 Intel Corporation
+ *
+ *  This library is free software; you can redistribute it and/or
+ *  modify it under the terms of the GNU Lesser General Public License
+ *  as published by the Free Software Foundation; either version 2.1
+ *  of the License, or (at your option) any later version.
+ *
+ *  This library is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ *  Lesser General Public License for more details.
+ *
+ *  You should have received a copy of the GNU Lesser General Public
+ *  License along with this library; if not, write to the Free
+ *  Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ *  Boston, MA 02110-1301 USA
+ */
+
+#ifndef GST_VAAPI_VIDEO_BUFFER_H
+#define GST_VAAPI_VIDEO_BUFFER_H
+
+#include <gst/vaapi/gstvaapivideometa.h>
+
+G_BEGIN_DECLS
+
+typedef struct _GstVaapiVideoBuffer             GstVaapiVideoBuffer;
+
+G_GNUC_INTERNAL
+GstBuffer *
+gst_vaapi_video_buffer_new(GstVaapiVideoMeta *meta);
+
+G_GNUC_INTERNAL
+GstVaapiVideoMeta *
+gst_vaapi_video_buffer_get_meta(GstVaapiVideoBuffer *buffer);
+
+G_END_DECLS
+
+#endif /* GST_VAAPI_VIDEO_BUFFER_H */
index 70e2edf..97aa655 100644 (file)
@@ -25,6 +25,7 @@
 #define GST_VAAPI_VIDEO_CONVERTER_GLX_H
 
 #include <gst/video/gstsurfaceconverter.h>
+#include "gstvaapivideobuffer.h"
 
 G_BEGIN_DECLS