From 75658894acd6eb4eb1d6ae9c808c20fde6154aec Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Sun, 2 Nov 2003 14:09:39 +0000 Subject: Updated for the new plugin loading code Original commit message from CVS: Updated for the new plugin loading code --- gst/filter/gstiir.c | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) (limited to 'gst/filter/gstiir.c') diff --git a/gst/filter/gstiir.c b/gst/filter/gstiir.c index 61fff92b..185b1522 100644 --- a/gst/filter/gstiir.c +++ b/gst/filter/gstiir.c @@ -25,16 +25,13 @@ #include "gstfilter.h" #include "iir.h" -GstElementDetails gst_iir_details = { +static GstElementDetails gst_iir_details = GST_ELEMENT_DETAILS ( "IIR", "Filter/Audio/Effect", - "LGPL", "IIR filter based on vorbis code", - VERSION, - "Monty , "\ - "Thomas ", - "(C) 2001", -}; + "Monty , " + "Thomas " +); enum { /* FILL ME */ @@ -80,6 +77,7 @@ struct _GstIIRClass GstElementClass parent_class; }; +static void gst_iir_base_init (gpointer g_class); static void gst_iir_class_init (GstIIRClass * klass); static void gst_iir_init (GstIIR * filter); @@ -102,7 +100,9 @@ GType gst_iir_get_type (void) if (!iir_type) { static const GTypeInfo iir_info = { - sizeof (GstIIRClass), NULL, NULL, + sizeof (GstIIRClass), + gst_iir_base_init, + NULL, (GClassInitFunc) gst_iir_class_init, NULL, NULL, sizeof (GstIIR), 0, (GInstanceInitFunc) gst_iir_init, @@ -114,6 +114,18 @@ GType gst_iir_get_type (void) return iir_type; } +static void +gst_iir_base_init (gpointer g_class) +{ + GstElementClass *element_class = GST_ELEMENT_CLASS (g_class); + + /* register src pads */ + gst_element_class_add_pad_template (element_class, gst_filter_src_factory ()); + gst_element_class_add_pad_template (element_class, gst_filter_sink_factory ()); + + gst_element_class_set_details (element_class, &gst_iir_details); +} + static void gst_iir_class_init (GstIIRClass * klass) { -- cgit v1.2.1