basecamerabinsrc: GST_EXPORT -> GST_BASE_CAMERA_BIN_SRC_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.
This commit is contained in:
Tim-Philipp Müller 2018-03-13 12:29:08 +00:00
parent 6b8f92d84f
commit a4c2d1ea31
6 changed files with 48 additions and 12 deletions

View file

@ -10,6 +10,7 @@ libgstbasecamerabinsrc_@GST_API_VERSION@_la_SOURCES = \
libgstbasecamerabinsrc_@GST_API_VERSION@includedir = $(includedir)/gstreamer-@GST_API_VERSION@/gst/basecamerabinsrc
libgstbasecamerabinsrc_@GST_API_VERSION@include_HEADERS = \
basecamerabinsrc-prelude.h \
gstcamerabin-enum.h \
gstcamerabinpreview.h \
gstbasecamerasrc.h

View file

@ -0,0 +1,31 @@
/* GStreamer BaseCameraBinSrc Library
* Copyright (C) 2018 GStreamer developers
*
* basecamerasrc-prelude.h: prelude include header for gst-basecamerasrc 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_BASE_CAMERA_BIN_SRC_PRELUDE_H__
#define __GST_BASE_CAMERA_BIN_SRC_PRELUDE_H__
#include <gst/gst.h>
#ifndef GST_BASE_CAMERA_BIN_SRC_API
#define GST_BASE_CAMERA_BIN_SRC_API GST_EXPORT
#endif
#endif /* __GST_BASE_CAMERA_BIN_SRC_PRELUDE_H__ */

View file

@ -30,6 +30,7 @@
#include <gst/gst.h>
#include <gst/gstbin.h>
#include "basecamerabinsrc-prelude.h"
#include "gstcamerabin-enum.h"
#include "gstcamerabinpreview.h"
@ -49,7 +50,7 @@ G_BEGIN_DECLS
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_BASE_CAMERA_SRC))
#define GST_BASE_CAMERA_SRC_CAST(obj) \
((GstBaseCameraSrc *) (obj))
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
GType gst_base_camera_src_get_type (void);
typedef struct _GstBaseCameraSrc GstBaseCameraSrc;
@ -133,20 +134,20 @@ struct _GstBaseCameraSrcClass
#define MAX_ZOOM 10.0f
#define ZOOM_1X MIN_ZOOM
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
gboolean gst_base_camera_src_set_mode (GstBaseCameraSrc *self, GstCameraBinMode mode);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
void gst_base_camera_src_setup_zoom (GstBaseCameraSrc * self);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
void gst_base_camera_src_setup_preview (GstBaseCameraSrc * self, GstCaps * preview_caps);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
void gst_base_camera_src_finish_capture (GstBaseCameraSrc *self);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
void gst_base_camera_src_post_preview (GstBaseCameraSrc *self, GstSample * sample);
// XXX add methods to get/set img capture and vid capture caps..

View file

@ -27,6 +27,7 @@
#endif
#include <gst/gst.h>
#include "basecamerabinsrc-prelude.h"
G_BEGIN_DECLS
@ -55,7 +56,7 @@ typedef enum
#define GST_TYPE_CAMERABIN_MODE (gst_camerabin_mode_get_type ())
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
GType gst_camerabin_mode_get_type (void);
G_END_DECLS

View file

@ -28,6 +28,7 @@
#endif
#include <gst/gst.h>
#include "basecamerabinsrc-prelude.h"
typedef struct
{
@ -47,19 +48,19 @@ typedef struct
} GstCameraBinPreviewPipelineData;
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
GstCameraBinPreviewPipelineData *gst_camerabin_create_preview_pipeline (GstElement * element, GstElement * filter);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
void gst_camerabin_destroy_preview_pipeline (GstCameraBinPreviewPipelineData * preview);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
gboolean gst_camerabin_preview_pipeline_post (GstCameraBinPreviewPipelineData * preview, GstSample * sample);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
void gst_camerabin_preview_set_caps (GstCameraBinPreviewPipelineData * preview, GstCaps * caps);
GST_EXPORT
GST_BASE_CAMERA_BIN_SRC_API
gboolean gst_camerabin_preview_set_filter (GstCameraBinPreviewPipelineData * preview, GstElement * filter);
#endif /* #ifndef __CAMERABIN_PREVIEW_H_ */

View file

@ -4,6 +4,7 @@ camerabin_sources = [
'gstbasecamerasrc.c',
]
camerabin_headers = [
'basecamerabinsrc-prelude.h',
'gstcamerabin-enum.h',
'gstcamerabinpreview.h',
'gstbasecamerasrc.h',