XVid compiles again...I'm off to bed :)

Original commit message from CVS:
XVid compiles again...I'm off to bed :)
This commit is contained in:
Iain Holmes 2003-11-02 02:31:04 +00:00
parent 61c073c5d8
commit 343ee1744a
5 changed files with 43 additions and 56 deletions

View file

@ -85,16 +85,20 @@ gst_xvid_error (int errorcode)
}
static gboolean
plugin_init (GModule *module,
GstPlugin *plugin)
plugin_init (GstPlugin *plugin)
{
return (gst_xviddec_plugin_init(module, plugin) &&
gst_xvidenc_plugin_init(module, plugin));
return (gst_xviddec_plugin_init(plugin) &&
gst_xvidenc_plugin_init(plugin));
}
GstPluginDesc plugin_desc = {
GST_PLUGIN_DEFINE (
GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"xvid",
plugin_init
};
"XVid plugin library",
plugin_init,
VERSION,
"GPL",
GST_COPYRIGHT,
GST_PACKAGE,
GST_ORIGIN)

View file

@ -32,11 +32,8 @@
GstElementDetails gst_xviddec_details = {
"Xvid decoder",
"Codec/Video/Decoder",
"GPL",
"Xvid decoder based on xviddecore",
VERSION,
"Ronald Bultje <rbultje@ronald.bitfreak.net>",
"(C) 2003",
};
GST_PAD_TEMPLATE_FACTORY(sink_template,
@ -91,7 +88,7 @@ enum {
/* FILL ME */
};
static void gst_xviddec_base_init (gpointer g_class);
static void gst_xviddec_class_init (GstXvidDecClass *klass);
static void gst_xviddec_init (GstXvidDec *xviddec);
static void gst_xviddec_dispose (GObject *object);
@ -114,7 +111,7 @@ gst_xviddec_get_type(void)
{
static const GTypeInfo xviddec_info = {
sizeof(GstXvidDecClass),
NULL,
gst_xviddec_base_init,
NULL,
(GClassInitFunc) gst_xviddec_class_init,
NULL,
@ -130,6 +127,16 @@ gst_xviddec_get_type(void)
return xviddec_type;
}
static void
gst_xviddec_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 (sink_template));
gst_element_class_add_pad_template (element_class, GST_PAD_TEMPLATE_GET (src_template));
gst_element_class_set_details (element_class, &gst_xviddec_details);
}
static void
gst_xviddec_class_init (GstXvidDecClass *klass)
@ -381,25 +388,10 @@ gst_xviddec_connect (GstPad *pad,
gboolean
gst_xviddec_plugin_init (GModule *module,
GstPlugin *plugin)
gst_xviddec_plugin_init (GstPlugin *plugin)
{
GstElementFactory *factory;
/* create an elementfactory for the v4lmjpegsrcparse element */
factory = gst_element_factory_new("xviddec", GST_TYPE_XVIDDEC,
&gst_xviddec_details);
g_return_val_if_fail(factory != NULL, FALSE);
/* add pad templates */
gst_element_factory_add_pad_template(factory,
GST_PAD_TEMPLATE_GET(sink_template));
gst_element_factory_add_pad_template(factory,
GST_PAD_TEMPLATE_GET(src_template));
gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
gst_element_factory_set_rank(factory, GST_ELEMENT_RANK_PRIMARY);
if (!gst_element_register (plugin, "xviddec", GST_RANK_PRIMARY, GST_TYPE_XVIDDEC))
return FALSE;
return TRUE;
}

View file

@ -64,8 +64,7 @@ struct _GstXvidDecClass {
GType gst_xviddec_get_type(void);
gboolean gst_xviddec_plugin_init (GModule *module,
GstPlugin *plugin);
gboolean gst_xviddec_plugin_init (GstPlugin *plugin);
#ifdef __cplusplus
}

View file

@ -33,11 +33,8 @@
GstElementDetails gst_xvidenc_details = {
"Xvid encoder",
"Codec/Video/Encoder",
"GPL",
"Xvid encoder based on xvidencore",
VERSION,
"Ronald Bultje <rbultje@ronald.bitfreak.net>",
"(C) 2003",
};
GST_PAD_TEMPLATE_FACTORY(sink_template,
@ -94,7 +91,7 @@ enum {
ARG_BUFSIZE
};
static void gst_xvidenc_base_init (gpointer g_class);
static void gst_xvidenc_class_init (GstXvidEncClass *klass);
static void gst_xvidenc_init (GstXvidEnc *xvidenc);
static void gst_xvidenc_chain (GstPad *pad,
@ -125,7 +122,7 @@ gst_xvidenc_get_type(void)
{
static const GTypeInfo xvidenc_info = {
sizeof(GstXvidEncClass),
NULL,
gst_xvidenc_base_init,
NULL,
(GClassInitFunc) gst_xvidenc_class_init,
NULL,
@ -141,6 +138,15 @@ gst_xvidenc_get_type(void)
return xvidenc_type;
}
static void
gst_xvidenc_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 (sink_template));
gst_element_class_add_pad_template (element_class, GST_PAD_TEMPLATE_GET (src_template));
gst_element_class_set_details (element_class, &gst_xvidenc_details);
}
static void
gst_xvidenc_class_init (GstXvidEncClass *klass)
@ -479,26 +485,13 @@ gst_xvidenc_get_property (GObject *object,
gboolean
gst_xvidenc_plugin_init (GModule *module,
GstPlugin *plugin)
gst_xvidenc_plugin_init (GstPlugin *plugin)
{
GstElementFactory *factory;
if (!gst_library_load("gstvideo"))
return FALSE;
/* create an elementfactory for the v4lmjpegsrcparse element */
factory = gst_element_factory_new("xvidenc", GST_TYPE_XVIDENC,
&gst_xvidenc_details);
g_return_val_if_fail(factory != NULL, FALSE);
/* add pad templates */
gst_element_factory_add_pad_template(factory,
GST_PAD_TEMPLATE_GET(sink_template));
gst_element_factory_add_pad_template(factory,
GST_PAD_TEMPLATE_GET(src_template));
gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
if (!gst_element_register (plugin, "xvidenc", GST_RANK_NONE, GST_TYPE_XVIDENC))
return FALSE;
return TRUE;
}

View file

@ -73,8 +73,7 @@ struct _GstXvidEncClass {
GType gst_xvidenc_get_type(void);
gboolean gst_xvidenc_plugin_init (GModule *module,
GstPlugin *plugin);
gboolean gst_xvidenc_plugin_init (GstPlugin *plugin);
#ifdef __cplusplus
}