summaryrefslogtreecommitdiffstats
path: root/gst/deinterlace
diff options
context:
space:
mode:
authorJan Schmidt <thaytan@mad.scientist.com>2003-11-02 05:39:26 +0000
committerJan Schmidt <thaytan@mad.scientist.com>2003-11-02 05:39:26 +0000
commit8cf23985358eab8d7b6db7115387474268ffe384 (patch)
treeb1519f47a98dc800bbb4b99f3d6285a20efbd885 /gst/deinterlace
parent343ee1744acb4046b84a68e012b0d5040761aff2 (diff)
downloadgst-plugins-bad-8cf23985358eab8d7b6db7115387474268ffe384.tar.gz
gst-plugins-bad-8cf23985358eab8d7b6db7115387474268ffe384.tar.bz2
gst-plugins-bad-8cf23985358eab8d7b6db7115387474268ffe384.zip
Updated for the new plugin loading code
Original commit message from CVS: Updated for the new plugin loading code
Diffstat (limited to 'gst/deinterlace')
-rw-r--r--gst/deinterlace/gstdeinterlace.c50
1 files changed, 29 insertions, 21 deletions
diff --git a/gst/deinterlace/gstdeinterlace.c b/gst/deinterlace/gstdeinterlace.c
index 81384d81..27a112fc 100644
--- a/gst/deinterlace/gstdeinterlace.c
+++ b/gst/deinterlace/gstdeinterlace.c
@@ -30,11 +30,8 @@
static GstElementDetails deinterlace_details = {
"Deinterlace",
"Filter/Video",
- "LGPL",
"Deinterlace video",
- VERSION,
- "Wim Taymans <wim.taymans@chello.be>",
- "(C) 2001",
+ "Wim Taymans <wim.taymans@chello.be>"
};
@@ -82,6 +79,7 @@ GST_PAD_TEMPLATE_FACTORY (deinterlace_sink_factory,
static GType gst_deinterlace_get_type (void);
+static void gst_deinterlace_base_init (gpointer g_class);
static void gst_deinterlace_class_init (GstDeInterlaceClass *klass);
static void gst_deinterlace_init (GstDeInterlace *filter);
@@ -101,7 +99,8 @@ gst_deinterlace_get_type(void) {
if (!deinterlace_type) {
static const GTypeInfo deinterlace_info = {
- sizeof(GstDeInterlaceClass), NULL,
+ sizeof(GstDeInterlaceClass),
+ gst_deinterlace_base_init,
NULL,
(GClassInitFunc)gst_deinterlace_class_init,
NULL,
@@ -116,6 +115,19 @@ gst_deinterlace_get_type(void) {
}
static void
+gst_deinterlace_base_init (gpointer g_class)
+{
+ GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
+
+ gst_element_class_add_pad_template (element_class,
+ GST_PAD_TEMPLATE_GET (deinterlace_src_factory));
+ gst_element_class_add_pad_template (element_class,
+ GST_PAD_TEMPLATE_GET (deinterlace_sink_factory));
+
+ gst_element_class_set_details (element_class, &deinterlace_details);
+}
+
+static void
gst_deinterlace_class_init (GstDeInterlaceClass *klass)
{
GObjectClass *gobject_class;
@@ -358,27 +370,23 @@ gst_deinterlace_get_property (GObject *object, guint prop_id, GValue *value, GPa
}
static gboolean
-plugin_init (GModule *module, GstPlugin *plugin)
+plugin_init (GstPlugin *plugin)
{
- GstElementFactory *factory;
-
- factory = gst_element_factory_new("deinterlace",GST_TYPE_DEINTERLACE,
- &deinterlace_details);
- g_return_val_if_fail(factory != NULL, FALSE);
-
- gst_element_factory_add_pad_template (factory,
- GST_PAD_TEMPLATE_GET (deinterlace_src_factory));
- gst_element_factory_add_pad_template (factory,
- GST_PAD_TEMPLATE_GET (deinterlace_sink_factory));
-
- gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
+ if (!gst_element_register (plugin, "deinterlace", GST_RANK_NONE, gst_deinterlace_get_type()))
+ return FALSE;
return TRUE;
}
-GstPluginDesc plugin_desc = {
+GST_PLUGIN_DEFINE (
GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"deinterlace",
- plugin_init
-};
+ "Deinterlace video",
+ plugin_init,
+ VERSION,
+ "LGPL",
+ GST_COPYRIGHT,
+ GST_PACKAGE,
+ GST_ORIGIN
+);