From 21a107294da941b50c87af9322af07191f4e7ffe Mon Sep 17 00:00:00 2001 From: Niels De Graef Date: Tue, 17 Mar 2020 18:20:59 +0100 Subject: [PATCH] streamvolume: Use G_DECLARE_INTERFACE --- gst-libs/gst/audio/streamvolume.h | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/gst-libs/gst/audio/streamvolume.h b/gst-libs/gst/audio/streamvolume.h index 4802d04b0f..2af4291aad 100644 --- a/gst-libs/gst/audio/streamvolume.h +++ b/gst-libs/gst/audio/streamvolume.h @@ -25,17 +25,12 @@ G_BEGIN_DECLS -#define GST_TYPE_STREAM_VOLUME \ - (gst_stream_volume_get_type ()) -#define GST_STREAM_VOLUME(obj) \ - (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_STREAM_VOLUME, GstStreamVolume)) -#define GST_IS_STREAM_VOLUME(obj) \ - (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_STREAM_VOLUME)) -#define GST_STREAM_VOLUME_GET_INTERFACE(inst) \ - (G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_STREAM_VOLUME, GstStreamVolumeInterface)) +#define GST_TYPE_STREAM_VOLUME (gst_stream_volume_get_type ()) +GST_AUDIO_API +G_DECLARE_INTERFACE (GstStreamVolume, gst_stream_volume, GST, STREAM_VOLUME, + GObject) -typedef struct _GstStreamVolume GstStreamVolume; -typedef struct _GstStreamVolumeInterface GstStreamVolumeInterface; +#define GST_STREAM_VOLUME_GET_INTERFACE(obj) GST_STREAM_VOLUME_GET_IFACE(obj) struct _GstStreamVolumeInterface { GTypeInterface iface; @@ -59,9 +54,6 @@ typedef enum { GST_STREAM_VOLUME_FORMAT_DB } GstStreamVolumeFormat; -GST_AUDIO_API -GType gst_stream_volume_get_type (void); - GST_AUDIO_API void gst_stream_volume_set_volume (GstStreamVolume *volume, GstStreamVolumeFormat format,