summaryrefslogtreecommitdiff
path: root/ext/faad
diff options
context:
space:
mode:
authorMark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>2011-09-22 16:01:56 +0200
committerMark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>2011-09-22 16:06:07 +0200
commit131df954cefe12e98ba2df1737f27ddf1863ee2a (patch)
tree2cd7347454ab26e9ddd56cf1fb8210f0b7c7ed02 /ext/faad
parent7234914e0ffa64b9efb1855a26dbb5d243bccc54 (diff)
downloadgstreamer-plugins-bad-131df954cefe12e98ba2df1737f27ddf1863ee2a.tar.gz
faad: use some more boilerplate
Diffstat (limited to 'ext/faad')
-rw-r--r--ext/faad/gstfaad.c34
1 files changed, 3 insertions, 31 deletions
diff --git a/ext/faad/gstfaad.c b/ext/faad/gstfaad.c
index 0bd47a9f9..ae851da8a 100644
--- a/ext/faad/gstfaad.c
+++ b/ext/faad/gstfaad.c
@@ -140,9 +140,6 @@ static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src",
GST_STATIC_CAPS (STATIC_CAPS)
);
-static void gst_faad_base_init (GstFaadClass * klass);
-static void gst_faad_class_init (GstFaadClass * klass);
-static void gst_faad_init (GstFaad * faad);
static void gst_faad_reset (GstFaad * faad);
static gboolean gst_faad_start (GstAudioDecoder * dec);
@@ -157,35 +154,10 @@ static void gst_faad_flush (GstAudioDecoder * dec, gboolean hard);
static gboolean gst_faad_open_decoder (GstFaad * faad);
static void gst_faad_close_decoder (GstFaad * faad);
-static GstElementClass *parent_class; /* NULL */
-
-GType
-gst_faad_get_type (void)
-{
- static GType gst_faad_type = 0;
-
- if (!gst_faad_type) {
- static const GTypeInfo gst_faad_info = {
- sizeof (GstFaadClass),
- (GBaseInitFunc) gst_faad_base_init,
- NULL,
- (GClassInitFunc) gst_faad_class_init,
- NULL,
- NULL,
- sizeof (GstFaad),
- 0,
- (GInstanceInitFunc) gst_faad_init,
- };
-
- gst_faad_type = g_type_register_static (GST_TYPE_AUDIO_DECODER,
- "GstFaad", &gst_faad_info, 0);
- }
-
- return gst_faad_type;
-}
+GST_BOILERPLATE (GstFaad, gst_faad, GstAudioDecoder, GST_TYPE_AUDIO_DECODER);
static void
-gst_faad_base_init (GstFaadClass * klass)
+gst_faad_base_init (gpointer klass)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
@@ -218,7 +190,7 @@ gst_faad_class_init (GstFaadClass * klass)
}
static void
-gst_faad_init (GstFaad * faad)
+gst_faad_init (GstFaad * faad, GstFaadClass * klass)
{
gst_faad_reset (faad);
}