summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2018-03-13 12:57:56 +0000
committerTim-Philipp Müller <tim@centricular.com>2018-03-13 12:57:56 +0000
commit456f60164c023075906c575a1b2cad8d25882d63 (patch)
tree21af7391d1b3b4398d8cb840ee227c37395d4321
parent3eb033bba27adb9bbeebaefe489d9ef75a419405 (diff)
opencv: GST_EXPORT -> GST_OPENCV_API
We need different export decorators for the different libs. For now no actual change though, just rename before the release, and add prelude headers to define the new decorator to GST_EXPORT.
-rw-r--r--gst-libs/gst/opencv/Makefile.am2
-rw-r--r--gst-libs/gst/opencv/gstopencvutils.h9
-rw-r--r--gst-libs/gst/opencv/gstopencvvideofilter.h5
-rw-r--r--gst-libs/gst/opencv/meson.build1
-rw-r--r--gst-libs/gst/opencv/opencv-prelude.h31
5 files changed, 42 insertions, 6 deletions
diff --git a/gst-libs/gst/opencv/Makefile.am b/gst-libs/gst/opencv/Makefile.am
index 9d18a5fc5..cc0d67f44 100644
--- a/gst-libs/gst/opencv/Makefile.am
+++ b/gst-libs/gst/opencv/Makefile.am
@@ -5,6 +5,7 @@ libgstopencv_@GST_API_VERSION@_la_SOURCES = \
gstopencvvideofilter.cpp
libgstopencv_@GST_API_VERSION@_la_CXXFLAGS = \
+ $(GST_PLUGINS_BAD_CFLAGS) \
$(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CXXFLAGS) \
$(OPENCV_CFLAGS)
@@ -17,5 +18,6 @@ libgstopencv_@GST_API_VERSION@_la_LDFLAGS = \
libgstopencv_@GST_API_VERSION@includedir = \
$(includedir)/gstreamer-@GST_API_VERSION@/gst/opencv
libgstopencv_@GST_API_VERSION@include_HEADERS = \
+ opencv-prelude.h \
gstopencvutils.h \
gstopencvvideofilter.h
diff --git a/gst-libs/gst/opencv/gstopencvutils.h b/gst-libs/gst/opencv/gstopencvutils.h
index d6aa6ca1e..3b74cc970 100644
--- a/gst-libs/gst/opencv/gstopencvutils.h
+++ b/gst-libs/gst/opencv/gstopencvutils.h
@@ -28,24 +28,25 @@
#include <gst/gst.h>
#include <gst/video/video.h>
+#include <gst/opencv/opencv-prelude.h>
G_BEGIN_DECLS
-GST_EXPORT
+GST_OPENCV_API
gboolean gst_opencv_parse_iplimage_params_from_caps
(GstCaps * caps, gint * width, gint * height, gint * depth,
gint * channels, GError ** err);
-GST_EXPORT
+GST_OPENCV_API
gboolean gst_opencv_iplimage_params_from_video_info
(GstVideoInfo * info, gint * width, gint * height, gint * depth,
gint * channels, GError ** err);
-GST_EXPORT
+GST_OPENCV_API
gboolean gst_opencv_cv_image_type_from_video_format (GstVideoFormat format,
int * cv_type, GError ** err);
-GST_EXPORT
+GST_OPENCV_API
GstCaps * gst_opencv_caps_from_cv_image_type (int cv_type);
G_END_DECLS
diff --git a/gst-libs/gst/opencv/gstopencvvideofilter.h b/gst-libs/gst/opencv/gstopencvvideofilter.h
index 2aa43e96e..58f1bda94 100644
--- a/gst-libs/gst/opencv/gstopencvvideofilter.h
+++ b/gst-libs/gst/opencv/gstopencvvideofilter.h
@@ -46,6 +46,7 @@
#include <gst/gst.h>
#include <gst/video/gstvideofilter.h>
+#include <gst/opencv/opencv-prelude.h>
G_BEGIN_DECLS
@@ -101,10 +102,10 @@ struct _GstOpencvVideoFilterClass
GstOpencvVideoFilterSetCaps cv_set_caps;
};
-GST_EXPORT
+GST_OPENCV_API
GType gst_opencv_video_filter_get_type (void);
-GST_EXPORT
+GST_OPENCV_API
void gst_opencv_video_filter_set_in_place (GstOpencvVideoFilter * transform,
gboolean ip);
diff --git a/gst-libs/gst/opencv/meson.build b/gst-libs/gst/opencv/meson.build
index 80639d3aa..ba132aa09 100644
--- a/gst-libs/gst/opencv/meson.build
+++ b/gst-libs/gst/opencv/meson.build
@@ -4,6 +4,7 @@ opencv_sources = [
]
opencv_headers = [
+ 'opencv-prelude.h',
'gstopencvutils.h',
'gstopencvvideofilter.h',
]
diff --git a/gst-libs/gst/opencv/opencv-prelude.h b/gst-libs/gst/opencv/opencv-prelude.h
new file mode 100644
index 000000000..2cbea56f9
--- /dev/null
+++ b/gst-libs/gst/opencv/opencv-prelude.h
@@ -0,0 +1,31 @@
+/* GStreamer OpenCV Library
+ * Copyright (C) 2018 GStreamer developers
+ *
+ * opencv-prelude.h: prelude include header for gst-opencv library
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 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
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#ifndef __GST_OPENCV_PRELUDE_H__
+#define __GST_OPENCV_PRELUDE_H__
+
+#include <gst/gst.h>
+
+#ifndef GST_OPENCV_API
+#define GST_OPENCV_API GST_EXPORT
+#endif
+
+#endif /* __GST_OPENCV_PRELUDE_H__ */