mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
interfaces: clean up the use of iface and class/klass
This commit is contained in:
parent
a586547b0c
commit
53d7d2e966
29 changed files with 242 additions and 258 deletions
|
@ -571,7 +571,7 @@ KISS_FFT_F64_SIN
|
|||
<FILE>gstcolorbalance</FILE>
|
||||
<INCLUDE>gst/interfaces/color.h</INCLUDE>
|
||||
GstColorBalance
|
||||
GstColorBalanceClass
|
||||
GstColorBalanceInterface
|
||||
GstColorBalanceType
|
||||
gst_color_balance_list_channels
|
||||
gst_color_balance_get_value
|
||||
|
@ -580,11 +580,9 @@ gst_color_balance_value_changed
|
|||
gst_color_balance_get_balance_type
|
||||
<SUBSECTION Standard>
|
||||
GST_COLOR_BALANCE
|
||||
GST_COLOR_BALANCE_CLASS
|
||||
GST_COLOR_BALANCE_GET_CLASS
|
||||
GST_COLOR_BALANCE_GET_INTERACE
|
||||
GST_COLOR_BALANCE_TYPE
|
||||
GST_IS_COLOR_BALANCE
|
||||
GST_IS_COLOR_BALANCE_CLASS
|
||||
GST_TYPE_COLOR_BALANCE
|
||||
GST_TYPE_COLOR_BALANCE_TYPE
|
||||
gst_color_balance_get_type
|
||||
|
@ -647,11 +645,9 @@ GST_TYPE_MIXER_TYPE
|
|||
GST_TYPE_MIXER_FLAGS
|
||||
GST_TYPE_MIXER_MESSAGE_TYPE
|
||||
GST_MIXER
|
||||
GST_MIXER_CLASS
|
||||
GST_MIXER_GET_CLASS
|
||||
GST_MIXER_GET_INTERFACE
|
||||
GST_MIXER_TYPE
|
||||
GST_IS_MIXER
|
||||
GST_IS_MIXER_CLASS
|
||||
GST_TYPE_STREAM_VOLUME_FORMAT
|
||||
gst_mixer_get_type
|
||||
gst_mixer_type_get_type
|
||||
|
@ -740,7 +736,7 @@ GST_NAVIGATION_COMMAND_DVD_TITLE_MENU
|
|||
<SUBSECTION Standard>
|
||||
GST_TYPE_NAVIGATION
|
||||
GST_NAVIGATION
|
||||
GST_NAVIGATION_GET_IFACE
|
||||
GST_NAVIGATION_GET_INTERFACE
|
||||
GST_TYPE_NAVIGATION_COMMAND
|
||||
GST_TYPE_NAVIGATION_EVENT_TYPE
|
||||
GST_TYPE_NAVIGATION_MESSAGE_TYPE
|
||||
|
@ -773,7 +769,7 @@ gst_property_probe_probe_property_name
|
|||
<SUBSECTION Standard>
|
||||
GST_TYPE_PROPERTY_PROBE
|
||||
GST_PROPERTY_PROBE
|
||||
GST_PROPERTY_PROBE_GET_IFACE
|
||||
GST_PROPERTY_PROBE_GET_INTEFACE
|
||||
GST_IS_PROPERTY_PROBE
|
||||
gst_property_probe_get_type
|
||||
</SECTION>
|
||||
|
@ -807,7 +803,7 @@ gst_stream_volume_get_type
|
|||
<FILE>gsttuner</FILE>
|
||||
<INCLUDE>gst/interfaces/tuner.h</INCLUDE>
|
||||
GstTuner
|
||||
GstTunerClass
|
||||
GstTunerInterface
|
||||
|
||||
gst_tuner_list_channels
|
||||
gst_tuner_get_channel
|
||||
|
@ -831,10 +827,8 @@ gst_tuner_signal_changed
|
|||
<SUBSECTION Standard>
|
||||
GST_TYPE_TUNER
|
||||
GST_TUNER
|
||||
GST_TUNER_CLASS
|
||||
GST_TUNER_GET_CLASS
|
||||
GST_TUNER_GET_INTERFACE
|
||||
GST_IS_TUNER
|
||||
GST_IS_TUNER_CLASS
|
||||
gst_tuner_get_type
|
||||
</SECTION>
|
||||
|
||||
|
@ -887,7 +881,7 @@ gst_video_orientation_set_vflip
|
|||
GST_TYPE_VIDEO_ORIENTATION
|
||||
GST_VIDEO_ORIENTATION
|
||||
GST_IS_VIDEO_ORIENTATION
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE
|
||||
gst_video_orientation_get_type
|
||||
</SECTION>
|
||||
|
||||
|
@ -906,7 +900,7 @@ gst_video_overlay_set_render_rectangle
|
|||
GST_TYPE_VIDEO_OVERLAY
|
||||
GST_VIDEO_OVERLAY
|
||||
GST_IS_VIDEO_OVERLAY
|
||||
GST_VIDEO_OVERLAY_GET_IFACE
|
||||
GST_VIDEO_OVERLAY_GET_INTERFACE
|
||||
gst_video_overlay_get_type
|
||||
</SECTION>
|
||||
|
||||
|
@ -1619,7 +1613,7 @@ GstRTSPExtensionInterface
|
|||
<SUBSECTION Standard>
|
||||
GST_IS_RTSP_EXTENSION
|
||||
GST_RTSP_EXTENSION
|
||||
GST_RTSP_EXTENSION_GET_IFACE
|
||||
GST_RTSP_EXTENSION_GET_INTERFACE
|
||||
GST_TYPE_RTSP_EXTENSION
|
||||
gst_rtsp_extension_after_send
|
||||
gst_rtsp_extension_before_send
|
||||
|
|
|
@ -187,19 +187,19 @@ interface_as_function ## _get_mixer_flags (GstMixer * mixer)
|
|||
} \
|
||||
\
|
||||
static void \
|
||||
interface_as_function ## _interface_init (GstMixerClass * klass) \
|
||||
interface_as_function ## _interface_init (GstMixerInterface * iface) \
|
||||
{ \
|
||||
GST_MIXER_TYPE (klass) = GST_MIXER_HARDWARE; \
|
||||
GST_MIXER_TYPE (iface) = GST_MIXER_HARDWARE; \
|
||||
\
|
||||
/* set up the interface hooks */ \
|
||||
klass->list_tracks = interface_as_function ## _list_tracks; \
|
||||
klass->set_volume = interface_as_function ## _set_volume; \
|
||||
klass->get_volume = interface_as_function ## _get_volume; \
|
||||
klass->set_mute = interface_as_function ## _set_mute; \
|
||||
klass->set_record = interface_as_function ## _set_record; \
|
||||
klass->set_option = interface_as_function ## _set_option; \
|
||||
klass->get_option = interface_as_function ## _get_option; \
|
||||
klass->get_mixer_flags = interface_as_function ## _get_mixer_flags; \
|
||||
iface->list_tracks = interface_as_function ## _list_tracks; \
|
||||
iface->set_volume = interface_as_function ## _set_volume; \
|
||||
iface->get_volume = interface_as_function ## _get_volume; \
|
||||
iface->set_mute = interface_as_function ## _set_mute; \
|
||||
iface->set_record = interface_as_function ## _set_record; \
|
||||
iface->set_option = interface_as_function ## _set_option; \
|
||||
iface->get_option = interface_as_function ## _get_option; \
|
||||
iface->get_mixer_flags = interface_as_function ## _get_mixer_flags; \
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -96,7 +96,7 @@ gst_rtsp_extension_detect_server (GstRTSPExtension * ext, GstRTSPMessage * resp)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
gboolean res = TRUE;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->detect_server)
|
||||
res = iface->detect_server (ext, resp);
|
||||
|
||||
|
@ -109,7 +109,7 @@ gst_rtsp_extension_before_send (GstRTSPExtension * ext, GstRTSPMessage * req)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->before_send)
|
||||
res = iface->before_send (ext, req);
|
||||
|
||||
|
@ -123,7 +123,7 @@ gst_rtsp_extension_after_send (GstRTSPExtension * ext, GstRTSPMessage * req,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->after_send)
|
||||
res = iface->after_send (ext, req, resp);
|
||||
|
||||
|
@ -137,7 +137,7 @@ gst_rtsp_extension_parse_sdp (GstRTSPExtension * ext, GstSDPMessage * sdp,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->parse_sdp)
|
||||
res = iface->parse_sdp (ext, sdp, s);
|
||||
|
||||
|
@ -150,7 +150,7 @@ gst_rtsp_extension_setup_media (GstRTSPExtension * ext, GstSDPMedia * media)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->setup_media)
|
||||
res = iface->setup_media (ext, media);
|
||||
|
||||
|
@ -163,7 +163,7 @@ gst_rtsp_extension_configure_stream (GstRTSPExtension * ext, GstCaps * caps)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
gboolean res = TRUE;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->configure_stream)
|
||||
res = iface->configure_stream (ext, caps);
|
||||
|
||||
|
@ -177,7 +177,7 @@ gst_rtsp_extension_get_transports (GstRTSPExtension * ext,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->get_transports)
|
||||
res = iface->get_transports (ext, protocols, transport);
|
||||
|
||||
|
@ -190,7 +190,7 @@ gst_rtsp_extension_stream_select (GstRTSPExtension * ext, GstRTSPUrl * url)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->stream_select)
|
||||
res = iface->stream_select (ext, url);
|
||||
|
||||
|
@ -204,7 +204,7 @@ gst_rtsp_extension_receive_request (GstRTSPExtension * ext,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_ENOTIMPL;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->receive_request)
|
||||
res = iface->receive_request (ext, msg);
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ G_BEGIN_DECLS
|
|||
(GST_IMPLEMENTS_INTERFACE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_AUDIO_PROCESS, GstAudioProcess))
|
||||
#define GST_IS_AUDIO_PROCESS(obj) \
|
||||
(GST_IMPLEMENTS_INTERFACE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_AUDIO_PROCESS))
|
||||
#define GST_AUDIO_PROCESS_GET_IFACE(inst) \
|
||||
#define GST_AUDIO_PROCESS_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_AUDIO_PROCESS, GstAudioProcessInterface))
|
||||
|
||||
typedef struct _GstAudioProcess GstAudioProcess;
|
||||
|
|
|
@ -52,7 +52,7 @@ enum
|
|||
LAST_SIGNAL
|
||||
};
|
||||
|
||||
static void gst_color_balance_class_init (GstColorBalanceClass * klass);
|
||||
static void gst_color_balance_class_init (GstColorBalanceInterface * iface);
|
||||
|
||||
static guint gst_color_balance_signals[LAST_SIGNAL] = { 0 };
|
||||
|
||||
|
@ -63,7 +63,7 @@ gst_color_balance_get_type (void)
|
|||
|
||||
if (!gst_color_balance_type) {
|
||||
static const GTypeInfo gst_color_balance_info = {
|
||||
sizeof (GstColorBalanceClass),
|
||||
sizeof (GstColorBalanceInterface),
|
||||
(GBaseInitFunc) gst_color_balance_class_init,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -82,7 +82,7 @@ gst_color_balance_get_type (void)
|
|||
}
|
||||
|
||||
static void
|
||||
gst_color_balance_class_init (GstColorBalanceClass * klass)
|
||||
gst_color_balance_class_init (GstColorBalanceInterface * iface)
|
||||
{
|
||||
static gboolean initialized = FALSE;
|
||||
|
||||
|
@ -98,7 +98,7 @@ gst_color_balance_class_init (GstColorBalanceClass * klass)
|
|||
gst_color_balance_signals[VALUE_CHANGED] =
|
||||
g_signal_new ("value-changed",
|
||||
GST_TYPE_COLOR_BALANCE, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstColorBalanceClass, value_changed),
|
||||
G_STRUCT_OFFSET (GstColorBalanceInterface, value_changed),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_INT,
|
||||
G_TYPE_NONE, 2, GST_TYPE_COLOR_BALANCE_CHANNEL, G_TYPE_INT);
|
||||
|
@ -106,12 +106,12 @@ gst_color_balance_class_init (GstColorBalanceClass * klass)
|
|||
initialized = TRUE;
|
||||
}
|
||||
|
||||
klass->balance_type = GST_COLOR_BALANCE_SOFTWARE;
|
||||
iface->balance_type = GST_COLOR_BALANCE_SOFTWARE;
|
||||
|
||||
/* default virtual functions */
|
||||
klass->list_channels = NULL;
|
||||
klass->set_value = NULL;
|
||||
klass->get_value = NULL;
|
||||
iface->list_channels = NULL;
|
||||
iface->set_value = NULL;
|
||||
iface->get_value = NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -127,14 +127,14 @@ gst_color_balance_class_init (GstColorBalanceClass * klass)
|
|||
const GList *
|
||||
gst_color_balance_list_channels (GstColorBalance * balance)
|
||||
{
|
||||
GstColorBalanceClass *klass;
|
||||
GstColorBalanceInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_COLOR_BALANCE (balance), NULL);
|
||||
|
||||
klass = GST_COLOR_BALANCE_GET_CLASS (balance);
|
||||
iface = GST_COLOR_BALANCE_GET_INTERFACE (balance);
|
||||
|
||||
if (klass->list_channels) {
|
||||
return klass->list_channels (balance);
|
||||
if (iface->list_channels) {
|
||||
return iface->list_channels (balance);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -157,10 +157,10 @@ void
|
|||
gst_color_balance_set_value (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel, gint value)
|
||||
{
|
||||
GstColorBalanceClass *klass = GST_COLOR_BALANCE_GET_CLASS (balance);
|
||||
GstColorBalanceInterface *iface = GST_COLOR_BALANCE_GET_INTERFACE (balance);
|
||||
|
||||
if (klass->set_value) {
|
||||
klass->set_value (balance, channel, value);
|
||||
if (iface->set_value) {
|
||||
iface->set_value (balance, channel, value);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -182,14 +182,14 @@ gint
|
|||
gst_color_balance_get_value (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel)
|
||||
{
|
||||
GstColorBalanceClass *klass;
|
||||
GstColorBalanceInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_COLOR_BALANCE (balance), 0);
|
||||
|
||||
klass = GST_COLOR_BALANCE_GET_CLASS (balance);
|
||||
iface = GST_COLOR_BALANCE_GET_INTERFACE (balance);
|
||||
|
||||
if (klass->get_value) {
|
||||
return klass->get_value (balance, channel);
|
||||
if (iface->get_value) {
|
||||
return iface->get_value (balance, channel);
|
||||
}
|
||||
|
||||
return channel->min_value;
|
||||
|
@ -208,14 +208,14 @@ gst_color_balance_get_value (GstColorBalance * balance,
|
|||
GstColorBalanceType
|
||||
gst_color_balance_get_balance_type (GstColorBalance * balance)
|
||||
{
|
||||
GstColorBalanceClass *klass;
|
||||
GstColorBalanceInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_COLOR_BALANCE (balance),
|
||||
GST_COLOR_BALANCE_SOFTWARE);
|
||||
|
||||
klass = GST_COLOR_BALANCE_GET_CLASS (balance);
|
||||
iface = GST_COLOR_BALANCE_GET_INTERFACE (balance);
|
||||
|
||||
return klass->balance_type;
|
||||
return iface->balance_type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -33,20 +33,15 @@ G_BEGIN_DECLS
|
|||
(gst_color_balance_get_type ())
|
||||
#define GST_COLOR_BALANCE(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_COLOR_BALANCE, GstColorBalance))
|
||||
#define GST_COLOR_BALANCE_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_COLOR_BALANCE, \
|
||||
GstColorBalanceClass))
|
||||
#define GST_IS_COLOR_BALANCE(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_COLOR_BALANCE))
|
||||
#define GST_IS_COLOR_BALANCE_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_COLOR_BALANCE))
|
||||
#define GST_COLOR_BALANCE_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_COLOR_BALANCE, GstColorBalanceClass))
|
||||
#define GST_COLOR_BALANCE_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_COLOR_BALANCE, GstColorBalanceInterface))
|
||||
|
||||
#define GST_COLOR_BALANCE_TYPE(klass) (klass->balance_type)
|
||||
|
||||
typedef struct _GstColorBalance GstColorBalance;
|
||||
typedef struct _GstColorBalanceClass GstColorBalanceClass;
|
||||
typedef struct _GstColorBalanceInterface GstColorBalanceInterface;
|
||||
|
||||
/**
|
||||
* GstColorBalanceType:
|
||||
|
@ -67,7 +62,7 @@ typedef enum
|
|||
} GstColorBalanceType;
|
||||
|
||||
/**
|
||||
* GstColorBalanceClass:
|
||||
* GstColorBalanceInterface:
|
||||
* @klass: the parent interface
|
||||
* @balance_type: implementation type
|
||||
* @list_channels: list handled channels
|
||||
|
@ -77,7 +72,7 @@ typedef enum
|
|||
*
|
||||
* Color-balance interface.
|
||||
*/
|
||||
struct _GstColorBalanceClass {
|
||||
struct _GstColorBalanceInterface {
|
||||
GTypeInterface klass;
|
||||
|
||||
GstColorBalanceType balance_type;
|
||||
|
|
|
@ -67,7 +67,7 @@ static guint gst_mixer_signals[LAST_SIGNAL] = { 0 };
|
|||
|
||||
#endif
|
||||
|
||||
static void gst_mixer_class_init (GstMixerClass * klass);
|
||||
static void gst_mixer_class_init (GstMixerInterface * iface);
|
||||
|
||||
GType
|
||||
gst_mixer_get_type (void)
|
||||
|
@ -76,7 +76,7 @@ gst_mixer_get_type (void)
|
|||
|
||||
if (!gst_mixer_type) {
|
||||
static const GTypeInfo gst_mixer_info = {
|
||||
sizeof (GstMixerClass),
|
||||
sizeof (GstMixerInterface),
|
||||
(GBaseInitFunc) gst_mixer_class_init,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -95,7 +95,7 @@ gst_mixer_get_type (void)
|
|||
}
|
||||
|
||||
static void
|
||||
gst_mixer_class_init (GstMixerClass * klass)
|
||||
gst_mixer_class_init (GstMixerInterface * iface)
|
||||
{
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
static gboolean initialized = FALSE;
|
||||
|
@ -105,28 +105,28 @@ gst_mixer_class_init (GstMixerClass * klass)
|
|||
gst_mixer_signals[SIGNAL_RECORD_TOGGLED] =
|
||||
g_signal_new ("record-toggled",
|
||||
GST_TYPE_MIXER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstMixerClass, record_toggled),
|
||||
G_STRUCT_OFFSET (GstMixerInterface, record_toggled),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_BOOLEAN, G_TYPE_NONE, 2,
|
||||
GST_TYPE_MIXER_TRACK, G_TYPE_BOOLEAN);
|
||||
gst_mixer_signals[SIGNAL_MUTE_TOGGLED] =
|
||||
g_signal_new ("mute-toggled",
|
||||
GST_TYPE_MIXER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstMixerClass, mute_toggled),
|
||||
G_STRUCT_OFFSET (GstMixerInterface, mute_toggled),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_BOOLEAN, G_TYPE_NONE, 2,
|
||||
GST_TYPE_MIXER_TRACK, G_TYPE_BOOLEAN);
|
||||
gst_mixer_signals[SIGNAL_VOLUME_CHANGED] =
|
||||
g_signal_new ("volume-changed",
|
||||
GST_TYPE_MIXER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstMixerClass, volume_changed),
|
||||
G_STRUCT_OFFSET (GstMixerInterface, volume_changed),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_POINTER, G_TYPE_NONE, 2,
|
||||
GST_TYPE_MIXER_TRACK, G_TYPE_POINTER);
|
||||
gst_mixer_signals[SIGNAL_OPTION_CHANGED] =
|
||||
g_signal_new ("option-changed",
|
||||
GST_TYPE_MIXER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstMixerClass, option_changed),
|
||||
G_STRUCT_OFFSET (GstMixerInterface, option_changed),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_STRING, G_TYPE_NONE, 2,
|
||||
GST_TYPE_MIXER_OPTIONS, G_TYPE_STRING);
|
||||
|
@ -135,16 +135,16 @@ gst_mixer_class_init (GstMixerClass * klass)
|
|||
}
|
||||
#endif
|
||||
|
||||
klass->mixer_type = GST_MIXER_SOFTWARE;
|
||||
iface->mixer_type = GST_MIXER_SOFTWARE;
|
||||
|
||||
/* default virtual functions */
|
||||
klass->list_tracks = NULL;
|
||||
klass->set_volume = NULL;
|
||||
klass->get_volume = NULL;
|
||||
klass->set_mute = NULL;
|
||||
klass->set_record = NULL;
|
||||
klass->set_option = NULL;
|
||||
klass->get_option = NULL;
|
||||
iface->list_tracks = NULL;
|
||||
iface->set_volume = NULL;
|
||||
iface->get_volume = NULL;
|
||||
iface->set_mute = NULL;
|
||||
iface->set_record = NULL;
|
||||
iface->set_option = NULL;
|
||||
iface->get_option = NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -164,14 +164,14 @@ gst_mixer_class_init (GstMixerClass * klass)
|
|||
const GList *
|
||||
gst_mixer_list_tracks (GstMixer * mixer)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (mixer != NULL, NULL);
|
||||
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->list_tracks) {
|
||||
return klass->list_tracks (mixer);
|
||||
if (iface->list_tracks) {
|
||||
return iface->list_tracks (mixer);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -195,16 +195,16 @@ gst_mixer_list_tracks (GstMixer * mixer)
|
|||
void
|
||||
gst_mixer_set_volume (GstMixer * mixer, GstMixerTrack * track, gint * volumes)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_if_fail (mixer != NULL);
|
||||
g_return_if_fail (track != NULL);
|
||||
g_return_if_fail (volumes != NULL);
|
||||
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->set_volume) {
|
||||
klass->set_volume (mixer, track, volumes);
|
||||
if (iface->set_volume) {
|
||||
iface->set_volume (mixer, track, volumes);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -222,16 +222,16 @@ gst_mixer_set_volume (GstMixer * mixer, GstMixerTrack * track, gint * volumes)
|
|||
void
|
||||
gst_mixer_get_volume (GstMixer * mixer, GstMixerTrack * track, gint * volumes)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_if_fail (mixer != NULL);
|
||||
g_return_if_fail (track != NULL);
|
||||
g_return_if_fail (volumes != NULL);
|
||||
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->get_volume) {
|
||||
klass->get_volume (mixer, track, volumes);
|
||||
if (iface->get_volume) {
|
||||
iface->get_volume (mixer, track, volumes);
|
||||
} else {
|
||||
gint i;
|
||||
|
||||
|
@ -255,15 +255,15 @@ gst_mixer_get_volume (GstMixer * mixer, GstMixerTrack * track, gint * volumes)
|
|||
void
|
||||
gst_mixer_set_mute (GstMixer * mixer, GstMixerTrack * track, gboolean mute)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_if_fail (mixer != NULL);
|
||||
g_return_if_fail (track != NULL);
|
||||
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->set_mute) {
|
||||
klass->set_mute (mixer, track, mute);
|
||||
if (iface->set_mute) {
|
||||
iface->set_mute (mixer, track, mute);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -283,10 +283,10 @@ gst_mixer_set_mute (GstMixer * mixer, GstMixerTrack * track, gboolean mute)
|
|||
void
|
||||
gst_mixer_set_record (GstMixer * mixer, GstMixerTrack * track, gboolean record)
|
||||
{
|
||||
GstMixerClass *klass = GST_MIXER_GET_CLASS (mixer);
|
||||
GstMixerInterface *iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->set_record) {
|
||||
klass->set_record (mixer, track, record);
|
||||
if (iface->set_record) {
|
||||
iface->set_record (mixer, track, record);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -302,15 +302,15 @@ gst_mixer_set_record (GstMixer * mixer, GstMixerTrack * track, gboolean record)
|
|||
void
|
||||
gst_mixer_set_option (GstMixer * mixer, GstMixerOptions * opts, gchar * value)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_if_fail (mixer != NULL);
|
||||
g_return_if_fail (opts != NULL);
|
||||
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->set_option) {
|
||||
klass->set_option (mixer, opts, value);
|
||||
if (iface->set_option) {
|
||||
iface->set_option (mixer, opts, value);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -327,15 +327,15 @@ gst_mixer_set_option (GstMixer * mixer, GstMixerOptions * opts, gchar * value)
|
|||
const gchar *
|
||||
gst_mixer_get_option (GstMixer * mixer, GstMixerOptions * opts)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (mixer != NULL, NULL);
|
||||
g_return_val_if_fail (opts != NULL, NULL);
|
||||
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->get_option) {
|
||||
return klass->get_option (mixer, opts);
|
||||
if (iface->get_option) {
|
||||
return iface->get_option (mixer, opts);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -354,9 +354,9 @@ gst_mixer_get_option (GstMixer * mixer, GstMixerOptions * opts)
|
|||
GstMixerType
|
||||
gst_mixer_get_mixer_type (GstMixer * mixer)
|
||||
{
|
||||
GstMixerClass *klass = GST_MIXER_GET_CLASS (mixer);
|
||||
GstMixerInterface *iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
return klass->mixer_type;
|
||||
return iface->mixer_type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -370,13 +370,13 @@ gst_mixer_get_mixer_type (GstMixer * mixer)
|
|||
GstMixerFlags
|
||||
gst_mixer_get_mixer_flags (GstMixer * mixer)
|
||||
{
|
||||
GstMixerClass *klass;
|
||||
GstMixerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (mixer != NULL, FALSE);
|
||||
klass = GST_MIXER_GET_CLASS (mixer);
|
||||
iface = GST_MIXER_GET_INTERFACE (mixer);
|
||||
|
||||
if (klass->get_mixer_flags) {
|
||||
return klass->get_mixer_flags (mixer);
|
||||
if (iface->get_mixer_flags) {
|
||||
return iface->get_mixer_flags (mixer);
|
||||
}
|
||||
return GST_MIXER_FLAG_NONE;
|
||||
}
|
||||
|
|
|
@ -35,19 +35,15 @@ G_BEGIN_DECLS
|
|||
(gst_mixer_get_type ())
|
||||
#define GST_MIXER(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_MIXER, GstMixer))
|
||||
#define GST_MIXER_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_MIXER, GstMixerClass))
|
||||
#define GST_IS_MIXER(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_MIXER))
|
||||
#define GST_IS_MIXER_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_MIXER))
|
||||
#define GST_MIXER_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_MIXER, GstMixerClass))
|
||||
#define GST_MIXER_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_MIXER, GstMixerInterface))
|
||||
|
||||
#define GST_MIXER_TYPE(klass) (klass->mixer_type)
|
||||
|
||||
typedef struct _GstMixer GstMixer;
|
||||
typedef struct _GstMixerClass GstMixerClass;
|
||||
typedef struct _GstMixerInterface GstMixerInterface;
|
||||
|
||||
/**
|
||||
* GstMixerType:
|
||||
|
@ -116,7 +112,7 @@ typedef enum
|
|||
GST_MIXER_FLAG_GROUPING = (1<<2),
|
||||
} GstMixerFlags;
|
||||
|
||||
struct _GstMixerClass {
|
||||
struct _GstMixerInterface {
|
||||
GTypeInterface klass;
|
||||
|
||||
GstMixerType mixer_type;
|
||||
|
|
|
@ -111,7 +111,7 @@ gst_navigation_class_init (GstNavigationInterface * iface)
|
|||
void
|
||||
gst_navigation_send_event (GstNavigation * navigation, GstStructure * structure)
|
||||
{
|
||||
GstNavigationInterface *iface = GST_NAVIGATION_GET_IFACE (navigation);
|
||||
GstNavigationInterface *iface = GST_NAVIGATION_GET_INTERFACE (navigation);
|
||||
|
||||
if (iface->send_event) {
|
||||
iface->send_event (navigation, structure);
|
||||
|
|
|
@ -33,7 +33,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_NAVIGATION, GstNavigation))
|
||||
#define GST_IS_NAVIGATION(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_NAVIGATION))
|
||||
#define GST_NAVIGATION_GET_IFACE(obj) \
|
||||
#define GST_NAVIGATION_GET_INTERFACE(obj) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((obj), GST_TYPE_NAVIGATION, GstNavigationInterface))
|
||||
|
||||
typedef struct _GstNavigation GstNavigation;
|
||||
|
|
|
@ -116,7 +116,7 @@ gst_property_probe_get_properties (GstPropertyProbe * probe)
|
|||
g_return_val_if_fail (probe != NULL, NULL);
|
||||
g_return_val_if_fail (GST_IS_PROPERTY_PROBE (probe), NULL);
|
||||
|
||||
iface = GST_PROPERTY_PROBE_GET_IFACE (probe);
|
||||
iface = GST_PROPERTY_PROBE_GET_INTERFACE (probe);
|
||||
|
||||
if (iface->get_properties)
|
||||
return iface->get_properties (probe);
|
||||
|
@ -177,7 +177,7 @@ gst_property_probe_probe_property (GstPropertyProbe * probe,
|
|||
g_return_if_fail (GST_IS_PROPERTY_PROBE (probe));
|
||||
g_return_if_fail (pspec != NULL);
|
||||
|
||||
iface = GST_PROPERTY_PROBE_GET_IFACE (probe);
|
||||
iface = GST_PROPERTY_PROBE_GET_INTERFACE (probe);
|
||||
|
||||
if (iface->probe_property)
|
||||
iface->probe_property (probe, pspec->param_id, pspec);
|
||||
|
@ -232,7 +232,7 @@ gst_property_probe_needs_probe (GstPropertyProbe * probe,
|
|||
g_return_val_if_fail (GST_IS_PROPERTY_PROBE (probe), FALSE);
|
||||
g_return_val_if_fail (pspec != NULL, FALSE);
|
||||
|
||||
iface = GST_PROPERTY_PROBE_GET_IFACE (probe);
|
||||
iface = GST_PROPERTY_PROBE_GET_INTERFACE (probe);
|
||||
|
||||
if (iface->needs_probe)
|
||||
return iface->needs_probe (probe, pspec->param_id, pspec);
|
||||
|
@ -288,7 +288,7 @@ gst_property_probe_get_values (GstPropertyProbe * probe,
|
|||
g_return_val_if_fail (GST_IS_PROPERTY_PROBE (probe), NULL);
|
||||
g_return_val_if_fail (pspec != NULL, NULL);
|
||||
|
||||
iface = GST_PROPERTY_PROBE_GET_IFACE (probe);
|
||||
iface = GST_PROPERTY_PROBE_GET_INTERFACE (probe);
|
||||
|
||||
if (iface->get_values)
|
||||
return iface->get_values (probe, pspec->param_id, pspec);
|
||||
|
|
|
@ -32,7 +32,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_PROPERTY_PROBE, GstPropertyProbe))
|
||||
#define GST_IS_PROPERTY_PROBE(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_PROPERTY_PROBE))
|
||||
#define GST_PROPERTY_PROBE_GET_IFACE(obj) \
|
||||
#define GST_PROPERTY_PROBE_GET_INTERFACE(obj) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((obj), GST_TYPE_PROPERTY_PROBE, GstPropertyProbeInterface))
|
||||
|
||||
/**
|
||||
|
|
|
@ -83,7 +83,7 @@ enum
|
|||
LAST_SIGNAL
|
||||
};
|
||||
|
||||
static void gst_tuner_class_init (GstTunerClass * klass);
|
||||
static void gst_tuner_class_init (GstTunerInterface * iface);
|
||||
|
||||
static guint gst_tuner_signals[LAST_SIGNAL] = { 0 };
|
||||
|
||||
|
@ -94,7 +94,7 @@ gst_tuner_get_type (void)
|
|||
|
||||
if (!gst_tuner_type) {
|
||||
static const GTypeInfo gst_tuner_info = {
|
||||
sizeof (GstTunerClass),
|
||||
sizeof (GstTunerInterface),
|
||||
(GBaseInitFunc) gst_tuner_class_init,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -113,7 +113,7 @@ gst_tuner_get_type (void)
|
|||
}
|
||||
|
||||
static void
|
||||
gst_tuner_class_init (GstTunerClass * klass)
|
||||
gst_tuner_class_init (GstTunerInterface * iface)
|
||||
{
|
||||
static gboolean initialized = FALSE;
|
||||
|
||||
|
@ -128,7 +128,7 @@ gst_tuner_class_init (GstTunerClass * klass)
|
|||
gst_tuner_signals[NORM_CHANGED] =
|
||||
g_signal_new ("norm-changed",
|
||||
GST_TYPE_TUNER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstTunerClass, norm_changed),
|
||||
G_STRUCT_OFFSET (GstTunerInterface, norm_changed),
|
||||
NULL, NULL,
|
||||
g_cclosure_marshal_VOID__OBJECT, G_TYPE_NONE, 1, GST_TYPE_TUNER_NORM);
|
||||
/**
|
||||
|
@ -141,7 +141,7 @@ gst_tuner_class_init (GstTunerClass * klass)
|
|||
gst_tuner_signals[CHANNEL_CHANGED] =
|
||||
g_signal_new ("channel-changed",
|
||||
GST_TYPE_TUNER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstTunerClass, channel_changed),
|
||||
G_STRUCT_OFFSET (GstTunerInterface, channel_changed),
|
||||
NULL, NULL,
|
||||
g_cclosure_marshal_VOID__OBJECT, G_TYPE_NONE, 1,
|
||||
GST_TYPE_TUNER_CHANNEL);
|
||||
|
@ -155,7 +155,7 @@ gst_tuner_class_init (GstTunerClass * klass)
|
|||
gst_tuner_signals[FREQUENCY_CHANGED] =
|
||||
g_signal_new ("frequency-changed",
|
||||
GST_TYPE_TUNER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstTunerClass, frequency_changed),
|
||||
G_STRUCT_OFFSET (GstTunerInterface, frequency_changed),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_ULONG, G_TYPE_NONE, 2,
|
||||
GST_TYPE_TUNER_CHANNEL, G_TYPE_ULONG);
|
||||
|
@ -172,7 +172,7 @@ gst_tuner_class_init (GstTunerClass * klass)
|
|||
gst_tuner_signals[SIGNAL_CHANGED] =
|
||||
g_signal_new ("signal-changed",
|
||||
GST_TYPE_TUNER, G_SIGNAL_RUN_LAST,
|
||||
G_STRUCT_OFFSET (GstTunerClass, signal_changed),
|
||||
G_STRUCT_OFFSET (GstTunerInterface, signal_changed),
|
||||
NULL, NULL,
|
||||
gst_interfaces_marshal_VOID__OBJECT_INT, G_TYPE_NONE, 2,
|
||||
GST_TYPE_TUNER_CHANNEL, G_TYPE_INT);
|
||||
|
@ -181,17 +181,17 @@ gst_tuner_class_init (GstTunerClass * klass)
|
|||
}
|
||||
|
||||
/* default virtual functions */
|
||||
klass->list_channels = NULL;
|
||||
klass->set_channel = NULL;
|
||||
klass->get_channel = NULL;
|
||||
iface->list_channels = NULL;
|
||||
iface->set_channel = NULL;
|
||||
iface->get_channel = NULL;
|
||||
|
||||
klass->list_norms = NULL;
|
||||
klass->set_norm = NULL;
|
||||
klass->get_norm = NULL;
|
||||
iface->list_norms = NULL;
|
||||
iface->set_norm = NULL;
|
||||
iface->get_norm = NULL;
|
||||
|
||||
klass->set_frequency = NULL;
|
||||
klass->get_frequency = NULL;
|
||||
klass->signal_strength = NULL;
|
||||
iface->set_frequency = NULL;
|
||||
iface->get_frequency = NULL;
|
||||
iface->signal_strength = NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -207,13 +207,13 @@ gst_tuner_class_init (GstTunerClass * klass)
|
|||
const GList *
|
||||
gst_tuner_list_channels (GstTuner * tuner)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_TUNER (tuner), NULL);
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->list_channels) {
|
||||
return klass->list_channels (tuner);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->list_channels) {
|
||||
return iface->list_channels (tuner);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -231,13 +231,13 @@ gst_tuner_list_channels (GstTuner * tuner)
|
|||
void
|
||||
gst_tuner_set_channel (GstTuner * tuner, GstTunerChannel * channel)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_if_fail (GST_IS_TUNER (tuner));
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->set_channel) {
|
||||
klass->set_channel (tuner, channel);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->set_channel) {
|
||||
iface->set_channel (tuner, channel);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -253,13 +253,13 @@ gst_tuner_set_channel (GstTuner * tuner, GstTunerChannel * channel)
|
|||
GstTunerChannel *
|
||||
gst_tuner_get_channel (GstTuner * tuner)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_TUNER (tuner), NULL);
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->get_channel) {
|
||||
return klass->get_channel (tuner);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->get_channel) {
|
||||
return iface->get_channel (tuner);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -280,13 +280,13 @@ gst_tuner_get_channel (GstTuner * tuner)
|
|||
const GList *
|
||||
gst_tuner_list_norms (GstTuner * tuner)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_TUNER (tuner), NULL);
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->list_norms) {
|
||||
return klass->list_norms (tuner);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->list_norms) {
|
||||
return iface->list_norms (tuner);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -304,13 +304,13 @@ gst_tuner_list_norms (GstTuner * tuner)
|
|||
void
|
||||
gst_tuner_set_norm (GstTuner * tuner, GstTunerNorm * norm)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_if_fail (GST_IS_TUNER (tuner));
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->set_norm) {
|
||||
klass->set_norm (tuner, norm);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->set_norm) {
|
||||
iface->set_norm (tuner, norm);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -327,13 +327,13 @@ gst_tuner_set_norm (GstTuner * tuner, GstTunerNorm * norm)
|
|||
GstTunerNorm *
|
||||
gst_tuner_get_norm (GstTuner * tuner)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_TUNER (tuner), NULL);
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->get_norm) {
|
||||
return klass->get_norm (tuner);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->get_norm) {
|
||||
return iface->get_norm (tuner);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
@ -360,16 +360,16 @@ void
|
|||
gst_tuner_set_frequency (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gulong frequency)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_if_fail (GST_IS_TUNER (tuner));
|
||||
g_return_if_fail (GST_IS_TUNER_CHANNEL (channel));
|
||||
g_return_if_fail (GST_TUNER_CHANNEL_HAS_FLAG (channel,
|
||||
GST_TUNER_CHANNEL_FREQUENCY));
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->set_frequency) {
|
||||
klass->set_frequency (tuner, channel, frequency);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->set_frequency) {
|
||||
iface->set_frequency (tuner, channel, frequency);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -388,17 +388,17 @@ gst_tuner_set_frequency (GstTuner * tuner,
|
|||
gulong
|
||||
gst_tuner_get_frequency (GstTuner * tuner, GstTunerChannel * channel)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_TUNER (tuner), 0);
|
||||
g_return_val_if_fail (GST_IS_TUNER_CHANNEL (channel), 0);
|
||||
g_return_val_if_fail (GST_TUNER_CHANNEL_HAS_FLAG (channel,
|
||||
GST_TUNER_CHANNEL_FREQUENCY), 0);
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
|
||||
if (klass->get_frequency) {
|
||||
return klass->get_frequency (tuner, channel);
|
||||
if (iface->get_frequency) {
|
||||
return iface->get_frequency (tuner, channel);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
@ -423,16 +423,16 @@ gst_tuner_get_frequency (GstTuner * tuner, GstTunerChannel * channel)
|
|||
gint
|
||||
gst_tuner_signal_strength (GstTuner * tuner, GstTunerChannel * channel)
|
||||
{
|
||||
GstTunerClass *klass;
|
||||
GstTunerInterface *iface;
|
||||
|
||||
g_return_val_if_fail (GST_IS_TUNER (tuner), 0);
|
||||
g_return_val_if_fail (GST_IS_TUNER_CHANNEL (channel), 0);
|
||||
g_return_val_if_fail (GST_TUNER_CHANNEL_HAS_FLAG (channel,
|
||||
GST_TUNER_CHANNEL_FREQUENCY), 0);
|
||||
|
||||
klass = GST_TUNER_GET_CLASS (tuner);
|
||||
if (klass->signal_strength) {
|
||||
return klass->signal_strength (tuner, channel);
|
||||
iface = GST_TUNER_GET_INTERFACE (tuner);
|
||||
if (iface->signal_strength) {
|
||||
return iface->signal_strength (tuner, channel);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
|
@ -35,20 +35,16 @@ G_BEGIN_DECLS
|
|||
(gst_tuner_get_type ())
|
||||
#define GST_TUNER(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_TUNER, GstTuner))
|
||||
#define GST_TUNER_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_TUNER, GstTunerClass))
|
||||
#define GST_IS_TUNER(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TUNER))
|
||||
#define GST_IS_TUNER_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_TUNER))
|
||||
#define GST_TUNER_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_TUNER, GstTunerClass))
|
||||
#define GST_TUNER_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_TUNER, GstTunerInterface))
|
||||
|
||||
typedef struct _GstTuner GstTuner;
|
||||
typedef struct _GstTunerClass GstTunerClass;
|
||||
typedef struct _GstTunerInterface GstTunerInterface;
|
||||
|
||||
/**
|
||||
* GstTunerClass:
|
||||
* GstTunerInterface:
|
||||
* @klass: the parent interface
|
||||
* @list_channels: list available channels
|
||||
* @set_channel: set to a channel
|
||||
|
@ -66,7 +62,7 @@ typedef struct _GstTunerClass GstTunerClass;
|
|||
*
|
||||
* Tuner interface.
|
||||
*/
|
||||
struct _GstTunerClass {
|
||||
struct _GstTunerInterface {
|
||||
GTypeInterface klass;
|
||||
|
||||
/* virtual functions */
|
||||
|
|
|
@ -101,7 +101,7 @@ gst_video_orientation_get_hflip (GstVideoOrientation * video_orientation,
|
|||
gboolean * flip)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->get_hflip) {
|
||||
return iface->get_hflip (video_orientation, flip);
|
||||
|
@ -124,7 +124,7 @@ gst_video_orientation_get_vflip (GstVideoOrientation * video_orientation,
|
|||
gboolean * flip)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->get_vflip) {
|
||||
return iface->get_vflip (video_orientation, flip);
|
||||
|
@ -147,7 +147,7 @@ gst_video_orientation_get_hcenter (GstVideoOrientation * video_orientation,
|
|||
gint * center)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->get_hcenter) {
|
||||
return iface->get_hcenter (video_orientation, center);
|
||||
|
@ -170,7 +170,7 @@ gst_video_orientation_get_vcenter (GstVideoOrientation * video_orientation,
|
|||
gint * center)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->get_vcenter) {
|
||||
return iface->get_vcenter (video_orientation, center);
|
||||
|
@ -193,7 +193,7 @@ gst_video_orientation_set_hflip (GstVideoOrientation * video_orientation,
|
|||
gboolean flip)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->set_hflip) {
|
||||
return iface->set_hflip (video_orientation, flip);
|
||||
|
@ -216,7 +216,7 @@ gst_video_orientation_set_vflip (GstVideoOrientation * video_orientation,
|
|||
gboolean flip)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->set_vflip) {
|
||||
return iface->set_vflip (video_orientation, flip);
|
||||
|
@ -239,7 +239,7 @@ gst_video_orientation_set_hcenter (GstVideoOrientation * video_orientation,
|
|||
gint center)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->set_hcenter) {
|
||||
return iface->set_hcenter (video_orientation, center);
|
||||
|
@ -262,7 +262,7 @@ gst_video_orientation_set_vcenter (GstVideoOrientation * video_orientation,
|
|||
gint center)
|
||||
{
|
||||
GstVideoOrientationInterface *iface =
|
||||
GST_VIDEO_ORIENTATION_GET_IFACE (video_orientation);
|
||||
GST_VIDEO_ORIENTATION_GET_INTERFACE (video_orientation);
|
||||
|
||||
if (iface->set_vcenter) {
|
||||
return iface->set_vcenter (video_orientation, center);
|
||||
|
|
|
@ -33,7 +33,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_VIDEO_ORIENTATION, GstVideoOrientation))
|
||||
#define GST_IS_VIDEO_ORIENTATION(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_VIDEO_ORIENTATION))
|
||||
#define GST_VIDEO_ORIENTATION_GET_IFACE(inst) \
|
||||
#define GST_VIDEO_ORIENTATION_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_VIDEO_ORIENTATION, GstVideoOrientationInterface))
|
||||
|
||||
/**
|
||||
|
|
|
@ -298,7 +298,7 @@ gst_video_overlay_get_type (void)
|
|||
|
||||
if (!gst_video_overlay_type) {
|
||||
static const GTypeInfo gst_video_overlay_info = {
|
||||
sizeof (GstVideoOverlayIface),
|
||||
sizeof (GstVideoOverlayInterface),
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -331,12 +331,12 @@ gst_video_overlay_get_type (void)
|
|||
void
|
||||
gst_video_overlay_set_window_handle (GstVideoOverlay * overlay, guintptr handle)
|
||||
{
|
||||
GstVideoOverlayIface *iface;
|
||||
GstVideoOverlayInterface *iface;
|
||||
|
||||
g_return_if_fail (overlay != NULL);
|
||||
g_return_if_fail (GST_IS_VIDEO_OVERLAY (overlay));
|
||||
|
||||
iface = GST_VIDEO_OVERLAY_GET_IFACE (overlay);
|
||||
iface = GST_VIDEO_OVERLAY_GET_INTERFACE (overlay);
|
||||
|
||||
if (iface->set_window_handle) {
|
||||
iface->set_window_handle (overlay, handle);
|
||||
|
@ -405,12 +405,12 @@ gst_video_overlay_prepare_window_handle (GstVideoOverlay * overlay)
|
|||
void
|
||||
gst_video_overlay_expose (GstVideoOverlay * overlay)
|
||||
{
|
||||
GstVideoOverlayIface *iface;
|
||||
GstVideoOverlayInterface *iface;
|
||||
|
||||
g_return_if_fail (overlay != NULL);
|
||||
g_return_if_fail (GST_IS_VIDEO_OVERLAY (overlay));
|
||||
|
||||
iface = GST_VIDEO_OVERLAY_GET_IFACE (overlay);
|
||||
iface = GST_VIDEO_OVERLAY_GET_INTERFACE (overlay);
|
||||
|
||||
if (iface->expose) {
|
||||
iface->expose (overlay);
|
||||
|
@ -434,12 +434,12 @@ void
|
|||
gst_video_overlay_handle_events (GstVideoOverlay * overlay,
|
||||
gboolean handle_events)
|
||||
{
|
||||
GstVideoOverlayIface *iface;
|
||||
GstVideoOverlayInterface *iface;
|
||||
|
||||
g_return_if_fail (overlay != NULL);
|
||||
g_return_if_fail (GST_IS_VIDEO_OVERLAY (overlay));
|
||||
|
||||
iface = GST_VIDEO_OVERLAY_GET_IFACE (overlay);
|
||||
iface = GST_VIDEO_OVERLAY_GET_INTERFACE (overlay);
|
||||
|
||||
if (iface->handle_events) {
|
||||
iface->handle_events (overlay, handle_events);
|
||||
|
@ -473,14 +473,14 @@ gboolean
|
|||
gst_video_overlay_set_render_rectangle (GstVideoOverlay * overlay,
|
||||
gint x, gint y, gint width, gint height)
|
||||
{
|
||||
GstVideoOverlayIface *iface;
|
||||
GstVideoOverlayInterface *iface;
|
||||
|
||||
g_return_val_if_fail (overlay != NULL, FALSE);
|
||||
g_return_val_if_fail (GST_IS_VIDEO_OVERLAY (overlay), FALSE);
|
||||
g_return_val_if_fail ((width == -1 && height == -1) ||
|
||||
(width > 0 && height > 0), FALSE);
|
||||
|
||||
iface = GST_VIDEO_OVERLAY_GET_IFACE (overlay);
|
||||
iface = GST_VIDEO_OVERLAY_GET_INTERFACE (overlay);
|
||||
|
||||
if (iface->set_render_rectangle) {
|
||||
iface->set_render_rectangle (overlay, x, y, width, height);
|
||||
|
|
|
@ -32,8 +32,8 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_VIDEO_OVERLAY, GstVideoOverlay))
|
||||
#define GST_IS_VIDEO_OVERLAY(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_VIDEO_OVERLAY))
|
||||
#define GST_VIDEO_OVERLAY_GET_IFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_VIDEO_OVERLAY, GstVideoOverlayIface))
|
||||
#define GST_VIDEO_OVERLAY_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_VIDEO_OVERLAY, GstVideoOverlayInterface))
|
||||
|
||||
/**
|
||||
* GstVideoOverlay:
|
||||
|
@ -41,10 +41,10 @@ G_BEGIN_DECLS
|
|||
* Opaque #GstVideoOverlay interface structure
|
||||
*/
|
||||
typedef struct _GstVideoOverlay GstVideoOverlay;
|
||||
typedef struct _GstVideoOverlayIface GstVideoOverlayIface;
|
||||
typedef struct _GstVideoOverlayInterface GstVideoOverlayInterface;
|
||||
|
||||
/**
|
||||
* GstVideoOverlayIface:
|
||||
* GstVideoOverlayInterface:
|
||||
* @interface: parent interface type.
|
||||
* @expose: virtual method to handle expose events
|
||||
* @handle_events: virtual method to handle events
|
||||
|
@ -53,7 +53,7 @@ typedef struct _GstVideoOverlayIface GstVideoOverlayIface;
|
|||
*
|
||||
* #GstVideoOverlay interface
|
||||
*/
|
||||
struct _GstVideoOverlayIface {
|
||||
struct _GstVideoOverlayInterface {
|
||||
GTypeInterface interface;
|
||||
|
||||
/* virtual functions */
|
||||
|
|
|
@ -96,7 +96,7 @@ gst_rtsp_extension_detect_server (GstRTSPExtension * ext, GstRTSPMessage * resp)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
gboolean res = TRUE;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->detect_server)
|
||||
res = iface->detect_server (ext, resp);
|
||||
|
||||
|
@ -109,7 +109,7 @@ gst_rtsp_extension_before_send (GstRTSPExtension * ext, GstRTSPMessage * req)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->before_send)
|
||||
res = iface->before_send (ext, req);
|
||||
|
||||
|
@ -123,7 +123,7 @@ gst_rtsp_extension_after_send (GstRTSPExtension * ext, GstRTSPMessage * req,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->after_send)
|
||||
res = iface->after_send (ext, req, resp);
|
||||
|
||||
|
@ -137,7 +137,7 @@ gst_rtsp_extension_parse_sdp (GstRTSPExtension * ext, GstSDPMessage * sdp,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->parse_sdp)
|
||||
res = iface->parse_sdp (ext, sdp, s);
|
||||
|
||||
|
@ -150,7 +150,7 @@ gst_rtsp_extension_setup_media (GstRTSPExtension * ext, GstSDPMedia * media)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->setup_media)
|
||||
res = iface->setup_media (ext, media);
|
||||
|
||||
|
@ -163,7 +163,7 @@ gst_rtsp_extension_configure_stream (GstRTSPExtension * ext, GstCaps * caps)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
gboolean res = TRUE;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->configure_stream)
|
||||
res = iface->configure_stream (ext, caps);
|
||||
|
||||
|
@ -177,7 +177,7 @@ gst_rtsp_extension_get_transports (GstRTSPExtension * ext,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->get_transports)
|
||||
res = iface->get_transports (ext, protocols, transport);
|
||||
|
||||
|
@ -190,7 +190,7 @@ gst_rtsp_extension_stream_select (GstRTSPExtension * ext, GstRTSPUrl * url)
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_OK;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->stream_select)
|
||||
res = iface->stream_select (ext, url);
|
||||
|
||||
|
@ -204,7 +204,7 @@ gst_rtsp_extension_receive_request (GstRTSPExtension * ext,
|
|||
GstRTSPExtensionInterface *iface;
|
||||
GstRTSPResult res = GST_RTSP_ENOTIMPL;
|
||||
|
||||
iface = GST_RTSP_EXTENSION_GET_IFACE (ext);
|
||||
iface = GST_RTSP_EXTENSION_GET_INTERFACE (ext);
|
||||
if (iface->receive_request)
|
||||
res = iface->receive_request (ext, msg);
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_RTSP_EXTENSION, GstRTSPExtension))
|
||||
#define GST_IS_RTSP_EXTENSION(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_RTSP_EXTENSION))
|
||||
#define GST_RTSP_EXTENSION_GET_IFACE(inst) \
|
||||
#define GST_RTSP_EXTENSION_GET_INTERFACE(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_RTSP_EXTENSION, GstRTSPExtensionInterface))
|
||||
|
||||
typedef struct _GstRTSPExtension GstRTSPExtension;
|
||||
|
|
|
@ -112,7 +112,7 @@ enum
|
|||
GST_AUDIO_CAPS_MAKE ("{ F32BE, F64BE, S8, S16BE, S24BE, S32BE }")
|
||||
#endif
|
||||
|
||||
static void gst_volume_mixer_init (GstMixerClass * iface);
|
||||
static void gst_volume_mixer_init (GstMixerInterface * iface);
|
||||
|
||||
#define gst_volume_parent_class parent_class
|
||||
G_DEFINE_TYPE_WITH_CODE (GstVolume, gst_volume,
|
||||
|
@ -335,15 +335,15 @@ gst_volume_set_mute (GstMixer * mixer, GstMixerTrack * track, gboolean mute)
|
|||
}
|
||||
|
||||
static void
|
||||
gst_volume_mixer_init (GstMixerClass * klass)
|
||||
gst_volume_mixer_init (GstMixerInterface * iface)
|
||||
{
|
||||
GST_MIXER_TYPE (klass) = GST_MIXER_SOFTWARE;
|
||||
GST_MIXER_TYPE (iface) = GST_MIXER_SOFTWARE;
|
||||
|
||||
/* default virtual functions */
|
||||
klass->list_tracks = gst_volume_list_tracks;
|
||||
klass->set_volume = gst_volume_set_volume;
|
||||
klass->get_volume = gst_volume_get_volume;
|
||||
klass->set_mute = gst_volume_set_mute;
|
||||
iface->list_tracks = gst_volume_list_tracks;
|
||||
iface->set_volume = gst_volume_set_volume;
|
||||
iface->get_volume = gst_volume_get_volume;
|
||||
iface->set_mute = gst_volume_set_mute;
|
||||
}
|
||||
|
||||
/* Element class */
|
||||
|
|
|
@ -168,8 +168,9 @@ enum
|
|||
/* Object typing & Creation */
|
||||
/* */
|
||||
/* =========================================== */
|
||||
static void gst_ximagesink_navigation_init (GstNavigationInterface * klass);
|
||||
static void gst_ximagesink_video_overlay_init (GstVideoOverlayIface * iface);
|
||||
static void gst_ximagesink_navigation_init (GstNavigationInterface * iface);
|
||||
static void gst_ximagesink_video_overlay_init (GstVideoOverlayInterface *
|
||||
iface);
|
||||
#define gst_ximagesink_parent_class parent_class
|
||||
G_DEFINE_TYPE_WITH_CODE (GstXImageSink, gst_ximagesink, GST_TYPE_VIDEO_SINK,
|
||||
G_IMPLEMENT_INTERFACE (GST_TYPE_NAVIGATION, gst_ximagesink_navigation_init);
|
||||
|
@ -1679,7 +1680,7 @@ gst_ximagesink_set_event_handling (GstVideoOverlay * overlay,
|
|||
}
|
||||
|
||||
static void
|
||||
gst_ximagesink_video_overlay_init (GstVideoOverlayIface * iface)
|
||||
gst_ximagesink_video_overlay_init (GstVideoOverlayInterface * iface)
|
||||
{
|
||||
iface->set_window_handle = gst_ximagesink_set_window_handle;
|
||||
iface->expose = gst_ximagesink_expose;
|
||||
|
|
|
@ -194,8 +194,10 @@ enum
|
|||
/* */
|
||||
/* =========================================== */
|
||||
static void gst_xvimagesink_navigation_init (GstNavigationInterface * iface);
|
||||
static void gst_xvimagesink_video_overlay_init (GstVideoOverlayIface * iface);
|
||||
static void gst_xvimagesink_colorbalance_init (GstColorBalanceClass * iface);
|
||||
static void gst_xvimagesink_video_overlay_init (GstVideoOverlayInterface *
|
||||
iface);
|
||||
static void gst_xvimagesink_colorbalance_init (GstColorBalanceInterface *
|
||||
iface);
|
||||
static void
|
||||
gst_xvimagesink_property_probe_interface_init (GstPropertyProbeInterface *
|
||||
iface);
|
||||
|
@ -2240,7 +2242,7 @@ gst_xvimagesink_set_render_rectangle (GstVideoOverlay * overlay, gint x, gint y,
|
|||
}
|
||||
|
||||
static void
|
||||
gst_xvimagesink_video_overlay_init (GstVideoOverlayIface * iface)
|
||||
gst_xvimagesink_video_overlay_init (GstVideoOverlayInterface * iface)
|
||||
{
|
||||
iface->set_window_handle = gst_xvimagesink_set_window_handle;
|
||||
iface->expose = gst_xvimagesink_expose;
|
||||
|
@ -2322,7 +2324,7 @@ gst_xvimagesink_colorbalance_get_value (GstColorBalance * balance,
|
|||
}
|
||||
|
||||
static void
|
||||
gst_xvimagesink_colorbalance_init (GstColorBalanceClass * iface)
|
||||
gst_xvimagesink_colorbalance_init (GstColorBalanceInterface * iface)
|
||||
{
|
||||
GST_COLOR_BALANCE_TYPE (iface) = GST_COLOR_BALANCE_HARDWARE;
|
||||
iface->list_channels = gst_xvimagesink_colorbalance_list_channels;
|
||||
|
|
|
@ -55,7 +55,7 @@ G_DEFINE_TYPE_WITH_CODE (TestElement, test_element, GST_TYPE_ELEMENT,
|
|||
init_interface (g_define_type_id));
|
||||
|
||||
static void
|
||||
test_element_mixer_interface_init (GstMixerClass * klass)
|
||||
test_element_mixer_interface_init (GstMixerInterface * iface)
|
||||
{
|
||||
/* Not actually implementing any interfaces for this test atm */
|
||||
}
|
||||
|
|
|
@ -61,9 +61,9 @@ G_DEFINE_TYPE_WITH_CODE (TestElement, test_element, GST_TYPE_ELEMENT,
|
|||
init_interface (g_define_type_id));
|
||||
|
||||
static void
|
||||
test_element_navigation_interface_init (GstNavigationInterface * klass)
|
||||
test_element_navigation_interface_init (GstNavigationInterface * iface)
|
||||
{
|
||||
klass->send_event = nav_send_event;
|
||||
iface->send_event = nav_send_event;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -31,7 +31,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstCddaBaseSrcTrack", sizeof (GstCddaBaseSrcTrack), 36},
|
||||
{"GstColorBalanceChannelClass", sizeof (GstColorBalanceChannelClass), 88},
|
||||
{"GstColorBalanceChannel", sizeof (GstColorBalanceChannel), 24},
|
||||
{"GstColorBalanceClass", sizeof (GstColorBalanceClass), 44},
|
||||
{"GstColorBalanceInterface", sizeof (GstColorBalanceInterface), 44},
|
||||
{"GstDiscovererClass", sizeof (GstDiscovererClass), 96},
|
||||
{"GstDiscoverer", sizeof (GstDiscoverer), 32},
|
||||
{"GstFFTF32Complex", sizeof (GstFFTF32Complex), 8},
|
||||
|
@ -42,7 +42,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstFFTS16", sizeof (GstFFTS16), 28},
|
||||
{"GstFFTS32Complex", sizeof (GstFFTS32Complex), 8},
|
||||
{"GstFFTS32", sizeof (GstFFTS32), 28},
|
||||
{"GstMixerClass", sizeof (GstMixerClass), 72},
|
||||
{"GstMixerInterface", sizeof (GstMixerInterface), 72},
|
||||
{"GstMixerOptionsClass", sizeof (GstMixerOptionsClass), 100},
|
||||
{"GstMixerOptions", sizeof (GstMixerOptions), 52},
|
||||
{"GstMixerTrackClass", sizeof (GstMixerTrackClass), 84},
|
||||
|
@ -86,7 +86,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstTagDemux", sizeof (GstTagDemux), 160},
|
||||
{"GstTunerChannelClass", sizeof (GstTunerChannelClass), 92},
|
||||
{"GstTunerChannel", sizeof (GstTunerChannel), 40},
|
||||
{"GstTunerClass", sizeof (GstTunerClass), 76},
|
||||
{"GstTunerInterface", sizeof (GstTunerInterface), 76},
|
||||
{"GstTunerNormClass", sizeof (GstTunerNormClass), 84},
|
||||
{"GstTunerNorm", sizeof (GstTunerNorm), 40},
|
||||
{"GstVideoFilterClass", sizeof (GstVideoFilterClass), 376},
|
||||
|
@ -95,6 +95,6 @@ GstCheckABIStruct list[] = {
|
|||
{"GstVideoRectangle", sizeof (GstVideoRectangle), 16},
|
||||
{"GstVideoSinkClass", sizeof (GstVideoSinkClass), 384},
|
||||
{"GstVideoSink", sizeof (GstVideoSink), 432},
|
||||
{"GstVideoOverlayIface", sizeof (GstVideoOverlayIface), 32},
|
||||
{"GstVideoOverlayInterface", sizeof (GstVideoOverlayInterface), 32},
|
||||
{NULL, 0, 0}
|
||||
};
|
||||
|
|
|
@ -29,7 +29,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstCddaBaseSrcTrack", sizeof (GstCddaBaseSrcTrack), 36},
|
||||
{"GstColorBalanceChannelClass", sizeof (GstColorBalanceChannelClass), 88},
|
||||
{"GstColorBalanceChannel", sizeof (GstColorBalanceChannel), 24},
|
||||
{"GstColorBalanceClass", sizeof (GstColorBalanceClass), 44},
|
||||
{"GstColorBalanceInterface", sizeof (GstColorBalanceInterface), 44},
|
||||
{"GstDiscovererClass", sizeof (GstDiscovererClass), 96},
|
||||
{"GstDiscoverer", sizeof (GstDiscoverer), 32},
|
||||
{"GstFFTF32Complex", sizeof (GstFFTF32Complex), 8},
|
||||
|
@ -40,7 +40,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstFFTS16", sizeof (GstFFTS16), 28},
|
||||
{"GstFFTS32Complex", sizeof (GstFFTS32Complex), 8},
|
||||
{"GstFFTS32", sizeof (GstFFTS32), 28},
|
||||
{"GstMixerClass", sizeof (GstMixerClass), 72},
|
||||
{"GstMixerInterface", sizeof (GstMixerInterface), 72},
|
||||
{"GstMixerOptionsClass", sizeof (GstMixerOptionsClass), 100},
|
||||
{"GstMixerOptions", sizeof (GstMixerOptions), 52},
|
||||
{"GstMixerTrackClass", sizeof (GstMixerTrackClass), 84},
|
||||
|
@ -82,7 +82,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstTagDemux", sizeof (GstTagDemux), 148},
|
||||
{"GstTunerChannelClass", sizeof (GstTunerChannelClass), 92},
|
||||
{"GstTunerChannel", sizeof (GstTunerChannel), 40},
|
||||
{"GstTunerClass", sizeof (GstTunerClass), 76},
|
||||
{"GstTunerInterface", sizeof (GstTunerInterface), 76},
|
||||
{"GstTunerNormClass", sizeof (GstTunerNormClass), 84},
|
||||
{"GstTunerNorm", sizeof (GstTunerNorm), 36},
|
||||
{"GstVideoFilterClass", sizeof (GstVideoFilterClass), 376},
|
||||
|
@ -91,6 +91,6 @@ GstCheckABIStruct list[] = {
|
|||
{"GstVideoRectangle", sizeof (GstVideoRectangle), 16},
|
||||
{"GstVideoSinkClass", sizeof (GstVideoSinkClass), 384},
|
||||
{"GstVideoSink", sizeof (GstVideoSink), 408},
|
||||
{"GstVideoOverlayIface", sizeof (GstVideoOverlayIface), 32},
|
||||
{"GstVideoOverlayInterface", sizeof (GstVideoOverlayInterface), 32},
|
||||
{NULL, 0, 0}
|
||||
};
|
||||
|
|
|
@ -31,7 +31,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstCddaBaseSrcTrack", sizeof (GstCddaBaseSrcTrack), 36},
|
||||
{"GstColorBalanceChannelClass", sizeof (GstColorBalanceChannelClass), 88},
|
||||
{"GstColorBalanceChannel", sizeof (GstColorBalanceChannel), 24},
|
||||
{"GstColorBalanceClass", sizeof (GstColorBalanceClass), 44},
|
||||
{"GstColorBalanceInterface", sizeof (GstColorBalanceInterface), 44},
|
||||
{"GstDiscovererClass", sizeof (GstDiscovererClass), 96},
|
||||
{"GstDiscoverer", sizeof (GstDiscoverer), 32},
|
||||
{"GstFFTF32Complex", sizeof (GstFFTF32Complex), 8},
|
||||
|
@ -42,7 +42,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstFFTS16", sizeof (GstFFTS16), 28},
|
||||
{"GstFFTS32Complex", sizeof (GstFFTS32Complex), 8},
|
||||
{"GstFFTS32", sizeof (GstFFTS32), 28},
|
||||
{"GstMixerClass", sizeof (GstMixerClass), 72},
|
||||
{"GstMixerInterface", sizeof (GstMixerInterface), 72},
|
||||
{"GstMixerOptionsClass", sizeof (GstMixerOptionsClass), 100},
|
||||
{"GstMixerOptions", sizeof (GstMixerOptions), 52},
|
||||
{"GstMixerTrackClass", sizeof (GstMixerTrackClass), 84},
|
||||
|
@ -86,7 +86,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstTagDemux", sizeof (GstTagDemux), 148},
|
||||
{"GstTunerChannelClass", sizeof (GstTunerChannelClass), 92},
|
||||
{"GstTunerChannel", sizeof (GstTunerChannel), 40},
|
||||
{"GstTunerClass", sizeof (GstTunerClass), 76},
|
||||
{"GstTunerInterface", sizeof (GstTunerInterface), 76},
|
||||
{"GstTunerNormClass", sizeof (GstTunerNormClass), 84},
|
||||
{"GstTunerNorm", sizeof (GstTunerNorm), 36},
|
||||
{"GstVideoFilterClass", sizeof (GstVideoFilterClass), 376},
|
||||
|
@ -95,6 +95,6 @@ GstCheckABIStruct list[] = {
|
|||
{"GstVideoRectangle", sizeof (GstVideoRectangle), 16},
|
||||
{"GstVideoSinkClass", sizeof (GstVideoSinkClass), 384},
|
||||
{"GstVideoSink", sizeof (GstVideoSink), 408},
|
||||
{"GstVideoOverlayIface", sizeof (GstVideoOverlayIface), 32},
|
||||
{"GstVideoOverlayInterface", sizeof (GstVideoOverlayInterface), 32},
|
||||
{NULL, 0, 0}
|
||||
};
|
||||
|
|
|
@ -29,7 +29,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstCddaBaseSrcTrack", sizeof (GstCddaBaseSrcTrack), 48},
|
||||
{"GstColorBalanceChannelClass", sizeof (GstColorBalanceChannelClass), 176},
|
||||
{"GstColorBalanceChannel", sizeof (GstColorBalanceChannel), 40},
|
||||
{"GstColorBalanceClass", sizeof (GstColorBalanceClass), 88},
|
||||
{"GstColorBalanceInterface", sizeof (GstColorBalanceInterface), 88},
|
||||
{"GstDiscovererClass", sizeof (GstDiscovererClass), 192},
|
||||
{"GstDiscoverer", sizeof (GstDiscoverer), 64},
|
||||
{"GstFFTF32Complex", sizeof (GstFFTF32Complex), 8},
|
||||
|
@ -40,7 +40,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstFFTS16", sizeof (GstFFTS16), 48},
|
||||
{"GstFFTS32Complex", sizeof (GstFFTS32Complex), 8},
|
||||
{"GstFFTS32", sizeof (GstFFTS32), 48},
|
||||
{"GstMixerClass", sizeof (GstMixerClass), 144},
|
||||
{"GstMixerInterface", sizeof (GstMixerInterface), 144},
|
||||
{"GstMixerOptionsClass", sizeof (GstMixerOptionsClass), 200},
|
||||
{"GstMixerOptions", sizeof (GstMixerOptions), 88},
|
||||
{"GstMixerTrackClass", sizeof (GstMixerTrackClass), 168},
|
||||
|
@ -82,7 +82,7 @@ GstCheckABIStruct list[] = {
|
|||
{"GstTagDemux", sizeof (GstTagDemux), 272},
|
||||
{"GstTunerChannelClass", sizeof (GstTunerChannelClass), 184},
|
||||
{"GstTunerChannel", sizeof (GstTunerChannel), 64},
|
||||
{"GstTunerClass", sizeof (GstTunerClass), 152},
|
||||
{"GstTunerInterface", sizeof (GstTunerInterface), 152},
|
||||
{"GstTunerNormClass", sizeof (GstTunerNormClass), 168},
|
||||
{"GstTunerNorm", sizeof (GstTunerNorm), 56},
|
||||
{"GstVideoFilterClass", sizeof (GstVideoFilterClass), 744},
|
||||
|
@ -91,6 +91,6 @@ GstCheckABIStruct list[] = {
|
|||
{"GstVideoRectangle", sizeof (GstVideoRectangle), 16},
|
||||
{"GstVideoSinkClass", sizeof (GstVideoSinkClass), 760},
|
||||
{"GstVideoSink", sizeof (GstVideoSink), 640},
|
||||
{"GstVideoOverlayIface", sizeof (GstVideoOverlayIface), 64},
|
||||
{"GstVideoOverlayInterface", sizeof (GstVideoOverlayInterface), 64},
|
||||
{NULL, 0, 0}
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue