player: mark symbols explicitly for export with GST_EXPORT

This commit is contained in:
Tim-Philipp Müller 2017-07-18 12:43:26 +01:00
parent 00bc9d7070
commit ce8485a585
8 changed files with 232 additions and 93 deletions

View file

@ -39,8 +39,10 @@ typedef struct _GstPlayerGMainContextSignalDispatcherClass
#define GST_PLAYER_G_MAIN_CONTEXT_SIGNAL_DISPATCHER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_PLAYER_G_MAIN_CONTEXT_SIGNAL_DISPATCHER, GstPlayerGMainContextSignalDispatcherClass))
#define GST_PLAYER_G_MAIN_CONTEXT_SIGNAL_DISPATCHER_CAST(obj) ((GstPlayerGMainContextSignalDispatcher*)(obj))
GST_EXPORT
GType gst_player_g_main_context_signal_dispatcher_get_type (void);
GST_EXPORT
GstPlayerSignalDispatcher * gst_player_g_main_context_signal_dispatcher_new (GMainContext * application_context);
G_END_DECLS

View file

@ -858,14 +858,6 @@ guint gst_player_media_info_get_number_of_subtitle_streams
return g_list_length (info->subtitle_stream_list);
}
#ifndef GST_REMOVE_DEPRECATED
#ifdef GST_DISABLE_DEPRECATED
/* Forward declarations */
GList *gst_player_get_video_streams (const GstPlayerMediaInfo * info);
GList *gst_player_get_audio_streams (const GstPlayerMediaInfo * info);
GList *gst_player_get_subtitle_streams (const GstPlayerMediaInfo * info);
#endif
/**
* gst_player_get_video_streams:
* @info: a #GstPlayerMediaInfo
@ -873,11 +865,13 @@ GList *gst_player_get_subtitle_streams (const GstPlayerMediaInfo * info);
* Returns: (transfer none) (element-type GstPlayerVideoInfo): A #GList of
* matching #GstPlayerVideoInfo.
*/
#ifndef GST_REMOVE_DEPRECATED
GList *
gst_player_get_video_streams (const GstPlayerMediaInfo * info)
{
return gst_player_media_info_get_video_streams (info);
}
#endif
/**
* gst_player_get_audio_streams:
@ -886,11 +880,13 @@ gst_player_get_video_streams (const GstPlayerMediaInfo * info)
* Returns: (transfer none) (element-type GstPlayerAudioInfo): A #GList of
* matching #GstPlayerAudioInfo.
*/
#ifndef GST_REMOVE_DEPRECATED
GList *
gst_player_get_audio_streams (const GstPlayerMediaInfo * info)
{
return gst_player_media_info_get_audio_streams (info);
}
#endif
/**
* gst_player_get_subtitle_streams:
@ -899,6 +895,7 @@ gst_player_get_audio_streams (const GstPlayerMediaInfo * info)
* Returns: (transfer none) (element-type GstPlayerSubtitleInfo): A #GList of
* matching #GstPlayerSubtitleInfo.
*/
#ifndef GST_REMOVE_DEPRECATED
GList *
gst_player_get_subtitle_streams (const GstPlayerMediaInfo * info)
{

View file

@ -45,18 +45,24 @@ G_BEGIN_DECLS
*/
typedef struct _GstPlayerStreamInfo GstPlayerStreamInfo;
typedef struct _GstPlayerStreamInfoClass GstPlayerStreamInfoClass;
GST_EXPORT
GType gst_player_stream_info_get_type (void);
gint gst_player_stream_info_get_index
(const GstPlayerStreamInfo *info);
const gchar* gst_player_stream_info_get_stream_type
(const GstPlayerStreamInfo *info);
GstTagList* gst_player_stream_info_get_tags
(const GstPlayerStreamInfo *info);
GstCaps* gst_player_stream_info_get_caps
(const GstPlayerStreamInfo *info);
const gchar* gst_player_stream_info_get_codec
(const GstPlayerStreamInfo *info);
GST_EXPORT
gint gst_player_stream_info_get_index (const GstPlayerStreamInfo *info);
GST_EXPORT
const gchar* gst_player_stream_info_get_stream_type (const GstPlayerStreamInfo *info);
GST_EXPORT
GstTagList* gst_player_stream_info_get_tags (const GstPlayerStreamInfo *info);
GST_EXPORT
GstCaps* gst_player_stream_info_get_caps (const GstPlayerStreamInfo *info);
GST_EXPORT
const gchar* gst_player_stream_info_get_codec (const GstPlayerStreamInfo *info);
#define GST_TYPE_PLAYER_VIDEO_INFO \
(gst_player_video_info_get_type ())
@ -76,20 +82,31 @@ const gchar* gst_player_stream_info_get_codec
*/
typedef struct _GstPlayerVideoInfo GstPlayerVideoInfo;
typedef struct _GstPlayerVideoInfoClass GstPlayerVideoInfoClass;
GST_EXPORT
GType gst_player_video_info_get_type (void);
gint gst_player_video_info_get_bitrate
(const GstPlayerVideoInfo* info);
gint gst_player_video_info_get_max_bitrate
(const GstPlayerVideoInfo* info);
gint gst_player_video_info_get_width
(const GstPlayerVideoInfo* info);
gint gst_player_video_info_get_height
(const GstPlayerVideoInfo* info);
void gst_player_video_info_get_framerate
(const GstPlayerVideoInfo* info, gint *fps_n, gint *fps_d);
void gst_player_video_info_get_pixel_aspect_ratio
(const GstPlayerVideoInfo* info, guint *par_n, guint *par_d);
GST_EXPORT
gint gst_player_video_info_get_bitrate (const GstPlayerVideoInfo * info);
GST_EXPORT
gint gst_player_video_info_get_max_bitrate (const GstPlayerVideoInfo * info);
GST_EXPORT
gint gst_player_video_info_get_width (const GstPlayerVideoInfo * info);
GST_EXPORT
gint gst_player_video_info_get_height (const GstPlayerVideoInfo * info);
GST_EXPORT
void gst_player_video_info_get_framerate (const GstPlayerVideoInfo * info,
gint * fps_n,
gint * fps_d);
GST_EXPORT
void gst_player_video_info_get_pixel_aspect_ratio (const GstPlayerVideoInfo * info,
guint * par_n,
guint * par_d);
#define GST_TYPE_PLAYER_AUDIO_INFO \
(gst_player_audio_info_get_type ())
@ -109,18 +126,24 @@ void gst_player_video_info_get_pixel_aspect_ratio
*/
typedef struct _GstPlayerAudioInfo GstPlayerAudioInfo;
typedef struct _GstPlayerAudioInfoClass GstPlayerAudioInfoClass;
GST_EXPORT
GType gst_player_audio_info_get_type (void);
gint gst_player_audio_info_get_channels
(const GstPlayerAudioInfo* info);
gint gst_player_audio_info_get_sample_rate
(const GstPlayerAudioInfo* info);
gint gst_player_audio_info_get_bitrate
(const GstPlayerAudioInfo* info);
gint gst_player_audio_info_get_max_bitrate
(const GstPlayerAudioInfo* info);
const gchar* gst_player_audio_info_get_language
(const GstPlayerAudioInfo* info);
GST_EXPORT
gint gst_player_audio_info_get_channels (const GstPlayerAudioInfo* info);
GST_EXPORT
gint gst_player_audio_info_get_sample_rate (const GstPlayerAudioInfo* info);
GST_EXPORT
gint gst_player_audio_info_get_bitrate (const GstPlayerAudioInfo* info);
GST_EXPORT
gint gst_player_audio_info_get_max_bitrate (const GstPlayerAudioInfo* info);
GST_EXPORT
const gchar* gst_player_audio_info_get_language (const GstPlayerAudioInfo* info);
#define GST_TYPE_PLAYER_SUBTITLE_INFO \
(gst_player_subtitle_info_get_type ())
@ -140,10 +163,12 @@ const gchar* gst_player_audio_info_get_language
*/
typedef struct _GstPlayerSubtitleInfo GstPlayerSubtitleInfo;
typedef struct _GstPlayerSubtitleInfoClass GstPlayerSubtitleInfoClass;
GST_EXPORT
GType gst_player_subtitle_info_get_type (void);
const gchar* gst_player_subtitle_info_get_language
(const GstPlayerSubtitleInfo* info);
GST_EXPORT
const gchar * gst_player_subtitle_info_get_language (const GstPlayerSubtitleInfo* info);
#define GST_TYPE_PLAYER_MEDIA_INFO \
(gst_player_media_info_get_type())
@ -163,48 +188,67 @@ const gchar* gst_player_subtitle_info_get_language
*/
typedef struct _GstPlayerMediaInfo GstPlayerMediaInfo;
typedef struct _GstPlayerMediaInfoClass GstPlayerMediaInfoClass;
GST_EXPORT
GType gst_player_media_info_get_type (void);
const gchar* gst_player_media_info_get_uri
(const GstPlayerMediaInfo *info);
gboolean gst_player_media_info_is_seekable
(const GstPlayerMediaInfo *info);
gboolean gst_player_media_info_is_live
(const GstPlayerMediaInfo *info);
GstClockTime gst_player_media_info_get_duration
(const GstPlayerMediaInfo *info);
GList* gst_player_media_info_get_stream_list
(const GstPlayerMediaInfo *info);
guint gst_player_media_info_get_number_of_streams
(const GstPlayerMediaInfo *info);
GList* gst_player_media_info_get_video_streams
(const GstPlayerMediaInfo *info);
guint gst_player_media_info_get_number_of_video_streams
(const GstPlayerMediaInfo *info);
GList* gst_player_media_info_get_audio_streams
(const GstPlayerMediaInfo *info);
guint gst_player_media_info_get_number_of_audio_streams
(const GstPlayerMediaInfo *info);
GList* gst_player_media_info_get_subtitle_streams
(const GstPlayerMediaInfo *info);
guint gst_player_media_info_get_number_of_subtitle_streams
(const GstPlayerMediaInfo *info);
GstTagList* gst_player_media_info_get_tags
(const GstPlayerMediaInfo *info);
const gchar* gst_player_media_info_get_title
(const GstPlayerMediaInfo *info);
const gchar* gst_player_media_info_get_container_format
(const GstPlayerMediaInfo *info);
GstSample* gst_player_media_info_get_image_sample
(const GstPlayerMediaInfo *info);
GST_EXPORT
const gchar * gst_player_media_info_get_uri (const GstPlayerMediaInfo *info);
#ifndef GST_DISABLE_DEPRECATED
GList* gst_player_get_video_streams
(const GstPlayerMediaInfo *info);
GList* gst_player_get_audio_streams
(const GstPlayerMediaInfo *info);
GList* gst_player_get_subtitle_streams
(const GstPlayerMediaInfo *info);
GST_EXPORT
gboolean gst_player_media_info_is_seekable (const GstPlayerMediaInfo *info);
GST_EXPORT
gboolean gst_player_media_info_is_live (const GstPlayerMediaInfo *info);
GST_EXPORT
GstClockTime gst_player_media_info_get_duration (const GstPlayerMediaInfo *info);
GST_EXPORT
GList* gst_player_media_info_get_stream_list (const GstPlayerMediaInfo *info);
GST_EXPORT
guint gst_player_media_info_get_number_of_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
GList* gst_player_media_info_get_video_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
guint gst_player_media_info_get_number_of_video_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
GList* gst_player_media_info_get_audio_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
guint gst_player_media_info_get_number_of_audio_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
GList* gst_player_media_info_get_subtitle_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
guint gst_player_media_info_get_number_of_subtitle_streams (const GstPlayerMediaInfo *info);
GST_EXPORT
GstTagList* gst_player_media_info_get_tags (const GstPlayerMediaInfo *info);
GST_EXPORT
const gchar* gst_player_media_info_get_title (const GstPlayerMediaInfo *info);
GST_EXPORT
const gchar* gst_player_media_info_get_container_format (const GstPlayerMediaInfo *info);
GST_EXPORT
GstSample* gst_player_media_info_get_image_sample (const GstPlayerMediaInfo *info);
#ifndef GST_REMOVE_DEPRECATED
GST_DEPRECATED_FOR(gst_player_media_info_get_video_streams)
GList* gst_player_get_video_streams (const GstPlayerMediaInfo *info);
GST_DEPRECATED_FOR(gst_player_media_info_get_audio_streams)
GList* gst_player_get_audio_streams (const GstPlayerMediaInfo *info);
GST_DEPRECATED_FOR(gst_player_media_info_get_subtitle_streams)
GList* gst_player_get_subtitle_streams (const GstPlayerMediaInfo *info);
#endif
G_END_DECLS

View file

@ -46,6 +46,7 @@ struct _GstPlayerSignalDispatcherInterface {
GDestroyNotify destroy);
};
GST_EXPORT
GType gst_player_signal_dispatcher_get_type (void);
G_END_DECLS

View file

@ -39,14 +39,28 @@ typedef struct _GstPlayerVideoOverlayVideoRendererClass
#define GST_PLAYER_VIDEO_OVERLAY_VIDEO_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_PLAYER_VIDEO_OVERLAY_VIDEO_RENDERER, GstPlayerVideoOverlayVideoRendererClass))
#define GST_PLAYER_VIDEO_OVERLAY_VIDEO_RENDERER_CAST(obj) ((GstPlayerVideoOverlayVideoRenderer*)(obj))
GST_EXPORT
GType gst_player_video_overlay_video_renderer_get_type (void);
GST_EXPORT
GstPlayerVideoRenderer * gst_player_video_overlay_video_renderer_new (gpointer window_handle);
GST_EXPORT
GstPlayerVideoRenderer * gst_player_video_overlay_video_renderer_new_with_sink (gpointer window_handle, GstElement * video_sink);
GST_EXPORT
void gst_player_video_overlay_video_renderer_set_window_handle (GstPlayerVideoOverlayVideoRenderer * self, gpointer window_handle);
GST_EXPORT
gpointer gst_player_video_overlay_video_renderer_get_window_handle (GstPlayerVideoOverlayVideoRenderer * self);
GST_EXPORT
void gst_player_video_overlay_video_renderer_expose (GstPlayerVideoOverlayVideoRenderer * self);
GST_EXPORT
void gst_player_video_overlay_video_renderer_set_render_rectangle (GstPlayerVideoOverlayVideoRenderer * self, gint x, gint y, gint width, gint height);
GST_EXPORT
void gst_player_video_overlay_video_renderer_get_render_rectangle (GstPlayerVideoOverlayVideoRenderer * self, gint *x, gint *y, gint *width, gint *height);
G_END_DECLS

View file

@ -40,6 +40,7 @@ struct _GstPlayerVideoRendererInterface {
GstElement * (*create_video_sink) (GstPlayerVideoRenderer * self, GstPlayer * player);
};
GST_EXPORT
GType gst_player_video_renderer_get_type (void);
G_END_DECLS

View file

@ -39,12 +39,19 @@ struct _GstPlayerVisualization {
gchar *description;
};
GST_EXPORT
GType gst_player_visualization_get_type (void);
GST_EXPORT
GstPlayerVisualization * gst_player_visualization_copy (const GstPlayerVisualization *vis);
GST_EXPORT
void gst_player_visualization_free (GstPlayerVisualization *vis);
GST_EXPORT
GstPlayerVisualization ** gst_player_visualizations_get (void);
GST_EXPORT
void gst_player_visualizations_free (GstPlayerVisualization **viss);
G_END_DECLS

View file

@ -30,6 +30,7 @@
G_BEGIN_DECLS
GST_EXPORT
GType gst_player_state_get_type (void);
#define GST_TYPE_PLAYER_STATE (gst_player_state_get_type ())
@ -49,9 +50,13 @@ typedef enum
GST_PLAYER_STATE_PLAYING
} GstPlayerState;
GST_EXPORT
const gchar *gst_player_state_get_name (GstPlayerState state);
GST_EXPORT
GQuark gst_player_error_quark (void);
GST_EXPORT
GType gst_player_error_get_type (void);
#define GST_PLAYER_ERROR (gst_player_error_quark ())
#define GST_TYPE_PLAYER_ERROR (gst_player_error_get_type ())
@ -64,8 +69,10 @@ typedef enum {
GST_PLAYER_ERROR_FAILED = 0
} GstPlayerError;
GST_EXPORT
const gchar *gst_player_error_get_name (GstPlayerError error);
GST_EXPORT
GType gst_player_color_balance_type_get_type (void);
#define GST_TYPE_PLAYER_COLOR_BALANCE_TYPE (gst_player_color_balance_type_get_type ())
@ -85,6 +92,7 @@ typedef enum
GST_PLAYER_COLOR_BALANCE_HUE,
} GstPlayerColorBalanceType;
GST_EXPORT
const gchar *gst_player_color_balance_type_get_name (GstPlayerColorBalanceType type);
#define GST_TYPE_PLAYER (gst_player_get_type ())
@ -96,113 +104,177 @@ const gchar *gst_player_color_balance_type_get_name (GstPlayerColorBalanceType
#define GST_PLAYER_CAST(obj) ((GstPlayer*)(obj))
GST_EXPORT
GType gst_player_get_type (void);
GST_EXPORT
GstPlayer * gst_player_new (GstPlayerVideoRenderer * video_renderer, GstPlayerSignalDispatcher * signal_dispatcher);
GST_EXPORT
void gst_player_play (GstPlayer * player);
GST_EXPORT
void gst_player_pause (GstPlayer * player);
GST_EXPORT
void gst_player_stop (GstPlayer * player);
GST_EXPORT
void gst_player_seek (GstPlayer * player,
GstClockTime position);
GST_EXPORT
void gst_player_set_rate (GstPlayer * player,
gdouble rate);
GST_EXPORT
gdouble gst_player_get_rate (GstPlayer * player);
GST_EXPORT
gchar * gst_player_get_uri (GstPlayer * player);
GST_EXPORT
void gst_player_set_uri (GstPlayer * player,
const gchar * uri);
GST_EXPORT
gchar * gst_player_get_subtitle_uri (GstPlayer * player);
GST_EXPORT
void gst_player_set_subtitle_uri (GstPlayer * player,
const gchar *uri);
GST_EXPORT
GstClockTime gst_player_get_position (GstPlayer * player);
GST_EXPORT
GstClockTime gst_player_get_duration (GstPlayer * player);
GST_EXPORT
gdouble gst_player_get_volume (GstPlayer * player);
GST_EXPORT
void gst_player_set_volume (GstPlayer * player,
gdouble val);
GST_EXPORT
gboolean gst_player_get_mute (GstPlayer * player);
GST_EXPORT
void gst_player_set_mute (GstPlayer * player,
gboolean val);
GST_EXPORT
GstElement * gst_player_get_pipeline (GstPlayer * player);
GST_EXPORT
void gst_player_set_video_track_enabled (GstPlayer * player,
gboolean enabled);
GST_EXPORT
void gst_player_set_audio_track_enabled (GstPlayer * player,
gboolean enabled);
GST_EXPORT
void gst_player_set_subtitle_track_enabled (GstPlayer * player,
gboolean enabled);
GST_EXPORT
gboolean gst_player_set_audio_track (GstPlayer *player,
gint stream_index);
GST_EXPORT
gboolean gst_player_set_video_track (GstPlayer *player,
gint stream_index);
GST_EXPORT
gboolean gst_player_set_subtitle_track (GstPlayer *player,
gint stream_index);
GST_EXPORT
GstPlayerMediaInfo * gst_player_get_media_info (GstPlayer * player);
GstPlayerAudioInfo * gst_player_get_current_audio_track
(GstPlayer * player);
GST_EXPORT
GstPlayerAudioInfo * gst_player_get_current_audio_track (GstPlayer * player);
GstPlayerVideoInfo * gst_player_get_current_video_track
(GstPlayer * player);
GST_EXPORT
GstPlayerVideoInfo * gst_player_get_current_video_track (GstPlayer * player);
GstPlayerSubtitleInfo * gst_player_get_current_subtitle_track
(GstPlayer * player);
GST_EXPORT
GstPlayerSubtitleInfo * gst_player_get_current_subtitle_track (GstPlayer * player);
GST_EXPORT
gboolean gst_player_set_visualization (GstPlayer * player,
const gchar *name);
GST_EXPORT
void gst_player_set_visualization_enabled (GstPlayer * player,
gboolean enabled);
GST_EXPORT
gchar * gst_player_get_current_visualization (GstPlayer * player);
GST_EXPORT
gboolean gst_player_has_color_balance (GstPlayer * player);
GST_EXPORT
void gst_player_set_color_balance (GstPlayer * player,
GstPlayerColorBalanceType type,
gdouble value);
GST_EXPORT
gdouble gst_player_get_color_balance (GstPlayer * player,
GstPlayerColorBalanceType type);
GST_EXPORT
GstVideoMultiviewMode gst_player_get_multiview_mode (GstPlayer * player);
GST_EXPORT
void gst_player_set_multiview_mode (GstPlayer * player,
GstVideoMultiviewMode mode);
GST_EXPORT
GstVideoMultiviewFlags gst_player_get_multiview_flags (GstPlayer * player);
GST_EXPORT
void gst_player_set_multiview_flags (GstPlayer * player,
GstVideoMultiviewFlags flags);
GST_EXPORT
gint64 gst_player_get_audio_video_offset (GstPlayer * player);
GST_EXPORT
void gst_player_set_audio_video_offset (GstPlayer * player,
gint64 offset);
GST_EXPORT
gboolean gst_player_set_config (GstPlayer * player,
GstStructure * config);
GST_EXPORT
GstStructure * gst_player_get_config (GstPlayer * player);
/* helpers for configuring the config structure */
GST_EXPORT
void gst_player_config_set_user_agent (GstStructure * config,
const gchar * agent);
GST_EXPORT
gchar * gst_player_config_get_user_agent (const GstStructure * config);
GST_EXPORT
void gst_player_config_set_position_update_interval (GstStructure * config,
guint interval);
GST_EXPORT
guint gst_player_config_get_position_update_interval (const GstStructure * config);
GST_EXPORT
void gst_player_config_set_seek_accurate (GstPlayer * player, gboolean accurate);
GST_EXPORT
gboolean gst_player_config_get_seek_accurate (const GstStructure * config);
typedef enum
@ -214,6 +286,7 @@ typedef enum
GST_PLAYER_THUMBNAIL_PNG
} GstPlayerSnapshotFormat;
GST_EXPORT
GstSample * gst_player_get_video_snapshot (GstPlayer * player,
GstPlayerSnapshotFormat format, GstStructure * config);