From: Iain Holmes Date: Sun, 2 Nov 2003 01:32:40 +0000 (+0000) Subject: Make smoothwave compile again X-Git-Tag: CAPS-ROOT~110 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7346fb1642e0f846626af925449a2e4164f5843b;p=platform%2Fupstream%2Fgst-plugins-good.git Make smoothwave compile again Original commit message from CVS: Make smoothwave compile again --- diff --git a/gst/smoothwave/gstsmoothwave.c b/gst/smoothwave/gstsmoothwave.c index 5fcd79c..807aa98 100644 --- a/gst/smoothwave/gstsmoothwave.c +++ b/gst/smoothwave/gstsmoothwave.c @@ -28,11 +28,8 @@ static GstElementDetails gst_smoothwave_details = { "Smooth waveform", "Visualization", - "LGPL", "Fading grayscale waveform display", - VERSION, "Erik Walthinsen ", - "(C) 1999", }; @@ -49,7 +46,7 @@ enum { ARG_WIDGET, }; - +static void gst_smoothwave_base_init (gpointer g_class); static void gst_smoothwave_class_init (GstSmoothWaveClass *klass); static void gst_smoothwave_init (GstSmoothWave *smoothwave); @@ -69,7 +66,8 @@ gst_smoothwave_get_type (void) if (!smoothwave_type) { static const GTypeInfo smoothwave_info = { - sizeof(GstSmoothWaveClass), NULL, + sizeof(GstSmoothWaveClass), + gst_smoothwave_base_init, NULL, (GClassInitFunc)gst_smoothwave_class_init, NULL, @@ -84,6 +82,14 @@ gst_smoothwave_get_type (void) } static void +gst_smoothwave_base_init (gpointer g_class) +{ + GstElementClass *element_class = GST_ELEMENT_CLASS (g_class); + + gst_element_class_set_details (element_class, &gst_smoothwave_details); +} + +static void gst_smoothwave_class_init (GstSmoothWaveClass *klass) { GObjectClass *gobject_class; @@ -288,23 +294,22 @@ gst_smoothwave_get_property (GObject *object, guint prop_id, GValue *value, GPar static gboolean -plugin_init (GModule *module, GstPlugin *plugin) +plugin_init (GstPlugin *plugin) { - GstElementFactory *factory; - - /* create an elementfactory for the smoothwave element */ - factory = gst_element_factory_new("smoothwave",GST_TYPE_SMOOTHWAVE, - &gst_smoothwave_details); - g_return_val_if_fail(factory != NULL, FALSE); - - gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory)); + if (!gst_element_register (plugin, "smoothwave", GST_RANK_NONE, GST_TYPE_SMOOTHWAVE)) + return FALSE; return TRUE; } -GstPluginDesc plugin_desc = { +GST_PLUGIN_DEFINE ( GST_VERSION_MAJOR, GST_VERSION_MINOR, "smoothwave", - plugin_init -}; + "Fading greyscale waveform display", + plugin_init, + VERSION, + "LGPL", + GST_COPYRIGHT, + GST_PACKAGE, + GST_ORIGIN)