Group all plugins into the same bundle
authorNicolas Dufresne <nicolas.dufresne@collabora.com>
Wed, 14 Sep 2011 19:12:41 +0000 (15:12 -0400)
committerGwenole Beauchesne <gwenole.beauchesne@intel.com>
Wed, 7 Dec 2011 13:33:59 +0000 (14:33 +0100)
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
13 files changed:
configure.ac
docs/reference/plugins/Makefile.am
gst/Makefile.am
gst/vaapi/Makefile.am [moved from gst/vaapisink/Makefile.am with 66% similarity]
gst/vaapi/gstvaapi.c [new file with mode: 0644]
gst/vaapi/gstvaapiconvert.c [moved from gst/vaapiconvert/gstvaapiconvert.c with 98% similarity]
gst/vaapi/gstvaapiconvert.h [moved from gst/vaapiconvert/gstvaapiconvert.h with 100% similarity]
gst/vaapi/gstvaapidecode.c [moved from gst/vaapidecode/gstvaapidecode.c with 97% similarity]
gst/vaapi/gstvaapidecode.h [moved from gst/vaapidecode/gstvaapidecode.h with 100% similarity]
gst/vaapi/gstvaapisink.c [moved from gst/vaapisink/gstvaapisink.c with 98% similarity]
gst/vaapi/gstvaapisink.h [moved from gst/vaapisink/gstvaapisink.h with 100% similarity]
gst/vaapiconvert/Makefile.am [deleted file]
gst/vaapidecode/Makefile.am [deleted file]

index e6e9842..0b9af9b 100644 (file)
@@ -333,9 +333,7 @@ pkgconfig/gstreamer-vaapi-glx.pc.in
     pkgconfig/gstreamer-vaapi-x11-$GST_MAJORMINOR.pc:\
 pkgconfig/gstreamer-vaapi-x11.pc.in
     gst/Makefile
     pkgconfig/gstreamer-vaapi-x11-$GST_MAJORMINOR.pc:\
 pkgconfig/gstreamer-vaapi-x11.pc.in
     gst/Makefile
-    gst/vaapiconvert/Makefile
-    gst/vaapidecode/Makefile
-    gst/vaapisink/Makefile
+    gst/vaapi/Makefile
     tests/Makefile
 ])
 
     tests/Makefile
 ])
 
index 457dfd1..0bb388c 100644 (file)
@@ -90,9 +90,7 @@ INCLUDES = \
 GTKDOC_LIBS = \
        $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-$(GST_MAJORMINOR).la \
        $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-x11-$(GST_MAJORMINOR).la \
 GTKDOC_LIBS = \
        $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-$(GST_MAJORMINOR).la \
        $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-x11-$(GST_MAJORMINOR).la \
-       $(top_builddir)/gst/vaapidecode/libgstvaapidecode.la \
-       $(top_builddir)/gst/vaapiconvert/libgstvaapiconvert.la \
-       $(top_builddir)/gst/vaapisink/libgstvaapisink.la \
+       $(top_builddir)/gst/vaapi/libgstvaapi.la \
        $(GLIB_LIBS) \
        $(GST_LIBS) \
        $(NULL)
        $(GLIB_LIBS) \
        $(GST_LIBS) \
        $(NULL)
index 195d0e9..37d365d 100644 (file)
@@ -1,4 +1,4 @@
-SUBDIRS = vaapiconvert vaapidecode vaapisink
+SUBDIRS = vaapi
 
 # Extra clean files so that maintainer-clean removes *everything*
 MAINTAINERCLEANFILES = Makefile.in
 
 # Extra clean files so that maintainer-clean removes *everything*
 MAINTAINERCLEANFILES = Makefile.in
similarity index 66%
rename from gst/vaapisink/Makefile.am
rename to gst/vaapi/Makefile.am
index a11b1b5..19bd410 100644 (file)
@@ -1,4 +1,4 @@
-plugin_LTLIBRARIES = libgstvaapisink.la
+plugin_LTLIBRARIES = libgstvaapi.la
 
 libgstvaapi_CFLAGS = \
        $(LIBVA_CFLAGS)         \
 
 libgstvaapi_CFLAGS = \
        $(LIBVA_CFLAGS)         \
@@ -12,30 +12,37 @@ libgstvaapi_LIBS = \
        $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-x11-$(GST_MAJORMINOR).la
 endif
 
        $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-x11-$(GST_MAJORMINOR).la
 endif
 
-libgstvaapisink_la_SOURCES =   \
+libgstvaapi_la_SOURCES =       \
+       gstvaapi.c              \
+       gstvaapiconvert.c       \
+       gstvaapidecode.c        \
        gstvaapisink.c          \
        $(NULL)
 
 noinst_HEADERS =               \
        gstvaapisink.c          \
        $(NULL)
 
 noinst_HEADERS =               \
+       gstvaapiconvert.h       \
+       gstvaapidecode.h        \
        gstvaapisink.h          \
        $(NULL)
 
        gstvaapisink.h          \
        $(NULL)
 
-libgstvaapisink_la_CFLAGS =    \
+libgstvaapi_la_CFLAGS =        \
        $(libgstvaapi_CFLAGS)   \
        $(GST_CFLAGS)           \
        $(libgstvaapi_CFLAGS)   \
        $(GST_CFLAGS)           \
+       $(GST_BASE_CFLAGS)      \
        $(GST_VIDEO_CFLAGS)     \
        $(GST_INTERFACES_CFLAGS) \
        $(GST_PLUGINS_BASE_CFLAGS)
 
        $(GST_VIDEO_CFLAGS)     \
        $(GST_INTERFACES_CFLAGS) \
        $(GST_PLUGINS_BASE_CFLAGS)
 
-libgstvaapisink_la_LIBADD =    \
+libgstvaapi_la_LIBADD =        \
        $(libgstvaapi_LIBS)     \
        $(GST_LIBS)             \
        $(libgstvaapi_LIBS)     \
        $(GST_LIBS)             \
+       $(GST_BASE_LIBS)        \
        $(GST_VIDEO_LIBS)       \
        $(GST_INTERFACES_LIBS)  \
        $(GST_PLUGINS_BASE_LIBS)
 
        $(GST_VIDEO_LIBS)       \
        $(GST_INTERFACES_LIBS)  \
        $(GST_PLUGINS_BASE_LIBS)
 
-libgstvaapisink_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
-libgstvaapisink_la_LIBTOOLFLAGS = --tag=disable-static
+libgstvaapi_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
+libgstvaapi_la_LIBTOOLFLAGS = --tag=disable-static
 
 # Extra clean files so that maintainer-clean removes *everything*
 MAINTAINERCLEANFILES = Makefile.in
 
 # Extra clean files so that maintainer-clean removes *everything*
 MAINTAINERCLEANFILES = Makefile.in
diff --git a/gst/vaapi/gstvaapi.c b/gst/vaapi/gstvaapi.c
new file mode 100644 (file)
index 0000000..1675a2a
--- /dev/null
@@ -0,0 +1,57 @@
+/*
+ *  gstvaapi.c - VA-API element registration
+ *
+ *  Copyright (C) 2011 Intel Corporation
+ *  Copyright (C) 2011 Collabora Ltd.
+ *    Author: Nicolas Dufresne <nicolas.dufresne@collabora.co.uk>
+ *
+ *  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
+ */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <gst/gst.h>
+
+#include "gstvaapiconvert.h"
+#include "gstvaapidecode.h"
+#include "gstvaapisink.h"
+
+static gboolean
+plugin_init (GstPlugin *plugin)
+{
+    gst_element_register(plugin, "vaapiconvert",
+                         GST_RANK_PRIMARY,
+                         GST_TYPE_VAAPICONVERT);
+    gst_element_register(plugin, "vaapidecode",
+                         GST_RANK_PRIMARY,
+                         GST_TYPE_VAAPIDECODE);
+    gst_element_register(plugin, "vaapisink",
+                         GST_RANK_PRIMARY,
+                         GST_TYPE_VAAPISINK);
+    return TRUE;
+}
+
+GST_PLUGIN_DEFINE(
+    GST_VERSION_MAJOR, GST_VERSION_MINOR,
+    "vaapi",
+    "VA-API based elements",
+    plugin_init,
+    PACKAGE_VERSION,
+    "LGPL",
+    PACKAGE,
+    PACKAGE_BUGREPORT);
similarity index 98%
rename from gst/vaapiconvert/gstvaapiconvert.c
rename to gst/vaapi/gstvaapiconvert.c
index 9b3b0b4..769176a 100644 (file)
@@ -240,6 +240,9 @@ gst_vaapiconvert_class_init(GstVaapiConvertClass *klass)
     GObjectClass * const object_class = G_OBJECT_CLASS(klass);
     GstBaseTransformClass * const trans_class = GST_BASE_TRANSFORM_CLASS(klass);
 
     GObjectClass * const object_class = G_OBJECT_CLASS(klass);
     GstBaseTransformClass * const trans_class = GST_BASE_TRANSFORM_CLASS(klass);
 
+    GST_DEBUG_CATEGORY_INIT(gst_debug_vaapiconvert,
+                            GST_PLUGIN_NAME, 0, GST_PLUGIN_DESC);
+
     object_class->finalize      = gst_vaapiconvert_finalize;
     object_class->set_property  = gst_vaapiconvert_set_property;
     object_class->get_property  = gst_vaapiconvert_get_property;
     object_class->finalize      = gst_vaapiconvert_finalize;
     object_class->set_property  = gst_vaapiconvert_set_property;
     object_class->get_property  = gst_vaapiconvert_get_property;
@@ -762,25 +765,3 @@ gst_vaapiconvert_prepare_output_buffer(
     *poutbuf = buffer;
     return GST_FLOW_OK;
 }
     *poutbuf = buffer;
     return GST_FLOW_OK;
 }
-
-static gboolean
-plugin_init(GstPlugin *plugin)
-{
-    GST_DEBUG_CATEGORY_INIT(gst_debug_vaapiconvert,
-                            GST_PLUGIN_NAME, 0, GST_PLUGIN_DESC);
-
-    return gst_element_register(plugin,
-                                GST_PLUGIN_NAME,
-                                GST_RANK_SECONDARY,
-                                GST_TYPE_VAAPICONVERT);
-}
-
-GST_PLUGIN_DEFINE(
-    GST_VERSION_MAJOR, GST_VERSION_MINOR,
-    GST_PLUGIN_NAME,
-    GST_PLUGIN_DESC,
-    plugin_init,
-    PACKAGE_VERSION,
-    "LGPL",
-    PACKAGE,
-    PACKAGE_BUGREPORT);
similarity index 97%
rename from gst/vaapidecode/gstvaapidecode.c
rename to gst/vaapi/gstvaapidecode.c
index a318776..19f0e91 100644 (file)
@@ -465,6 +465,9 @@ gst_vaapidecode_class_init(GstVaapiDecodeClass *klass)
     GObjectClass * const object_class = G_OBJECT_CLASS(klass);
     GstElementClass * const element_class = GST_ELEMENT_CLASS(klass);
 
     GObjectClass * const object_class = G_OBJECT_CLASS(klass);
     GstElementClass * const element_class = GST_ELEMENT_CLASS(klass);
 
+    GST_DEBUG_CATEGORY_INIT(gst_debug_vaapidecode,
+                            GST_PLUGIN_NAME, 0, GST_PLUGIN_DESC);
+
     object_class->finalize      = gst_vaapidecode_finalize;
     object_class->set_property  = gst_vaapidecode_set_property;
     object_class->get_property  = gst_vaapidecode_get_property;
     object_class->finalize      = gst_vaapidecode_finalize;
     object_class->set_property  = gst_vaapidecode_set_property;
     object_class->get_property  = gst_vaapidecode_get_property;
@@ -655,25 +658,3 @@ gst_vaapidecode_init(GstVaapiDecode *decode, GstVaapiDecodeClass *klass)
     gst_pad_set_event_function(decode->srcpad, gst_vaapidecode_src_event);
     gst_element_add_pad(GST_ELEMENT(decode), decode->srcpad);
 }
     gst_pad_set_event_function(decode->srcpad, gst_vaapidecode_src_event);
     gst_element_add_pad(GST_ELEMENT(decode), decode->srcpad);
 }
-
-static gboolean
-plugin_init(GstPlugin *plugin)
-{
-    GST_DEBUG_CATEGORY_INIT(gst_debug_vaapidecode,
-                            GST_PLUGIN_NAME, 0, GST_PLUGIN_DESC);
-
-    return gst_element_register(plugin,
-                                GST_PLUGIN_NAME,
-                                GST_RANK_PRIMARY,
-                                GST_TYPE_VAAPIDECODE);
-}
-
-GST_PLUGIN_DEFINE(
-    GST_VERSION_MAJOR, GST_VERSION_MINOR,
-    GST_PLUGIN_NAME,
-    GST_PLUGIN_DESC,
-    plugin_init,
-    PACKAGE_VERSION,
-    "LGPL",
-    PACKAGE,
-    PACKAGE_BUGREPORT);
similarity index 98%
rename from gst/vaapisink/gstvaapisink.c
rename to gst/vaapi/gstvaapisink.c
index 10f791b..b59f738 100644 (file)
@@ -808,6 +808,9 @@ gst_vaapisink_class_init(GstVaapiSinkClass *klass)
     GObjectClass * const     object_class   = G_OBJECT_CLASS(klass);
     GstBaseSinkClass * const basesink_class = GST_BASE_SINK_CLASS(klass);
 
     GObjectClass * const     object_class   = G_OBJECT_CLASS(klass);
     GstBaseSinkClass * const basesink_class = GST_BASE_SINK_CLASS(klass);
 
+    GST_DEBUG_CATEGORY_INIT(gst_debug_vaapisink,
+                            GST_PLUGIN_NAME, 0, GST_PLUGIN_DESC);
+
     object_class->finalize       = gst_vaapisink_finalize;
     object_class->set_property   = gst_vaapisink_set_property;
     object_class->get_property   = gst_vaapisink_get_property;
     object_class->finalize       = gst_vaapisink_finalize;
     object_class->set_property   = gst_vaapisink_set_property;
     object_class->get_property   = gst_vaapisink_get_property;
@@ -900,25 +903,3 @@ gst_vaapisink_get_display(GstVaapiSink *sink)
         return NULL;
     return sink->display;
 }
         return NULL;
     return sink->display;
 }
-
-static gboolean
-plugin_init(GstPlugin *plugin)
-{
-    GST_DEBUG_CATEGORY_INIT(gst_debug_vaapisink,
-                            GST_PLUGIN_NAME, 0, GST_PLUGIN_DESC);
-
-    return gst_element_register(plugin,
-                                GST_PLUGIN_NAME,
-                                GST_RANK_PRIMARY,
-                                GST_TYPE_VAAPISINK);
-}
-
-GST_PLUGIN_DEFINE(
-    GST_VERSION_MAJOR, GST_VERSION_MINOR,
-    GST_PLUGIN_NAME,
-    GST_PLUGIN_DESC,
-    plugin_init,
-    PACKAGE_VERSION,
-    "LGPL",
-    PACKAGE,
-    PACKAGE_BUGREPORT);
diff --git a/gst/vaapiconvert/Makefile.am b/gst/vaapiconvert/Makefile.am
deleted file mode 100644 (file)
index 545e4cb..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-plugin_LTLIBRARIES = libgstvaapiconvert.la
-
-libgstvaapi_CFLAGS = \
-       $(LIBVA_CFLAGS)         \
-       -I$(top_srcdir)/gst-libs
-
-libgstvaapi_LIBS = \
-       $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-$(GST_MAJORMINOR).la
-
-libgstvaapiconvert_la_SOURCES =        \
-       gstvaapiconvert.c       \
-       $(NULL)
-
-noinst_HEADERS =               \
-       gstvaapiconvert.h       \
-       $(NULL)
-
-libgstvaapiconvert_la_CFLAGS = \
-       $(libgstvaapi_CFLAGS)   \
-       $(GST_CFLAGS)           \
-       $(GST_BASE_CFLAGS)      \
-       $(GST_VIDEO_CFLAGS)     \
-       $(GST_PLUGINS_BASE_CFLAGS)
-
-libgstvaapiconvert_la_LIBADD = \
-       $(libgstvaapi_LIBS)     \
-       $(GST_LIBS)             \
-       $(GST_BASE_LIBS)        \
-       $(GST_VIDEO_LIBS)       \
-       $(GST_PLUGINS_BASE_LIBS)
-
-libgstvaapiconvert_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
-libgstvaapiconvert_la_LIBTOOLFLAGS = --tag=disable-static
-
-# Extra clean files so that maintainer-clean removes *everything*
-MAINTAINERCLEANFILES = Makefile.in
diff --git a/gst/vaapidecode/Makefile.am b/gst/vaapidecode/Makefile.am
deleted file mode 100644 (file)
index 17bf0c9..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-plugin_LTLIBRARIES = libgstvaapidecode.la
-
-libgstvaapi_CFLAGS = \
-       $(LIBVA_CFLAGS)         \
-       -I$(top_srcdir)/gst-libs
-
-libgstvaapi_LIBS = \
-       $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-x11-$(GST_MAJORMINOR).la
-
-libgstvaapidecode_la_SOURCES = \
-       gstvaapidecode.c        \
-       $(NULL)
-
-noinst_HEADERS =               \
-       gstvaapidecode.h        \
-       $(NULL)
-
-libgstvaapidecode_la_CFLAGS =  \
-       $(libgstvaapi_CFLAGS)   \
-       $(GST_CFLAGS)           \
-       $(GST_BASE_CFLAGS)      \
-       $(GST_VIDEO_CFLAGS)     \
-       $(GST_PLUGINS_BASE_CFLAGS)
-
-libgstvaapidecode_la_LIBADD =  \
-       $(libgstvaapi_LIBS)     \
-       $(GST_LIBS)             \
-       $(GST_BASE_LIBS)        \
-       $(GST_VIDEO_LIBS)       \
-       $(GST_PLUGINS_BASE_LIBS)
-
-libgstvaapidecode_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
-libgstvaapidecode_la_LIBTOOLFLAGS = --tag=disable-static
-
-# Extra clean files so that maintainer-clean removes *everything*
-MAINTAINERCLEANFILES = Makefile.in