Commit eabfbf13 authored by Benjamin Otte's avatar Benjamin Otte

fix most of sys dir. v4l2 and dxr3 pending, as I don't have them

Original commit message from CVS:
fix most of sys dir. v4l2 and dxr3 pending, as I don't have them
parent 59e0556a
......@@ -41,6 +41,7 @@ enum
LAST_SIGNAL,
};
static void cdplayer_base_init (gpointer g_class);
static void cdplayer_class_init (CDPlayerClass *klass);
static void cdplayer_init (CDPlayer *cdp);
static void cdplayer_dispose (GObject *object);
......@@ -57,16 +58,13 @@ static GstElementStateReturn
static GstElementClass *parent_class;
static guint cdplayer_signals[LAST_SIGNAL] = { 0 };
static GstElementDetails cdplayer_details = {
static GstElementDetails cdplayer_details = GST_ELEMENT_DETAILS (
"CD Player",
"Generic/Bin",
"LGPL", /* ? */
"Play CD audio through the CD Drive",
VERSION,
"Charles Schmidt <cbschmid@uiuc.edu>\n"
"Wim Taymans <wim.taymans@chello.be>",
"(C) 2002",
};
"Charles Schmidt <cbschmid@uiuc.edu>, "
"Wim Taymans <wim.taymans@chello.be>"
);
GType
......@@ -77,7 +75,7 @@ cdplayer_get_type (void)
if (!cdplayer_type) {
static const GTypeInfo cdplayer_info = {
sizeof (CDPlayerClass),
NULL,
cdplayer_base_init,
NULL,
(GClassInitFunc) cdplayer_class_init,
NULL,
......@@ -94,6 +92,13 @@ cdplayer_get_type (void)
return cdplayer_type;
}
static void
cdplayer_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_set_details (element_class, &cdplayer_details);
}
static void
cdplayer_class_init (CDPlayerClass * klass)
{
......@@ -349,23 +354,20 @@ cdplayer_change_state (GstElement * element)
static gboolean
plugin_init (GModule * module, GstPlugin * plugin)
plugin_init (GstPlugin * plugin)
{
GstElementFactory *factory;
factory = gst_element_factory_new ("cdplayer", GST_TYPE_CDPLAYER, &cdplayer_details);
g_return_val_if_fail (factory != NULL, FALSE);
gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
gst_plugin_set_longname (plugin, "CD Player");
return TRUE;
return gst_element_register (plugin, "cdplayer", GST_RANK_NONE, GST_TYPE_CDPLAYER);
}
GstPluginDesc plugin_desc = {
GST_PLUGIN_DEFINE (
GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"cdplayer",
plugin_init
};
"CD Player",
plugin_init,
VERSION,
GST_LICENSE, /* ? */
GST_COPYRIGHT,
GST_PACKAGE,
GST_ORIGIN
);
......@@ -34,17 +34,12 @@
#include "qcamip.h"
/* elementfactory information */
static GstElementDetails
gst_qcamsrc_details =
{
static GstElementDetails gst_qcamsrc_details = GST_ELEMENT_DETAILS (
"QCam Source",
"Source/Video",
"LGPL",
"Read from a QuickCam device",
VERSION,
"Wim Taymans <wim.taymans@chello.be>",
"(C) 2001",
};
"Wim Taymans <wim.taymans@chello.be>"
);
#define AE_NONE 3
......@@ -111,6 +106,7 @@ enum {
ARG_AUTOEXP,
};
static void gst_qcamsrc_base_init (gpointer g_class);
static void gst_qcamsrc_class_init (GstQCamSrcClass *klass);
static void gst_qcamsrc_init (GstQCamSrc *qcamsrc);
......@@ -136,7 +132,7 @@ gst_qcamsrc_get_type (void)
if (!qcamsrc_type) {
static const GTypeInfo qcamsrc_info = {
sizeof(GstQCamSrcClass),
NULL,
gst_qcamsrc_base_init,
NULL,
(GClassInitFunc)gst_qcamsrc_class_init,
NULL,
......@@ -150,7 +146,14 @@ gst_qcamsrc_get_type (void)
}
return qcamsrc_type;
}
static void
gst_qcamsrc_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 (gst_qcamsrc_src_factory));
gst_element_class_set_details (element_class, &gst_qcamsrc_details);
}
static void
gst_qcamsrc_class_init (GstQCamSrcClass *klass)
{
......@@ -424,27 +427,24 @@ gst_qcamsrc_close (GstQCamSrc *src)
}
static gboolean
plugin_init (GModule *module, GstPlugin *plugin)
plugin_init (GstPlugin *plugin)
{
GstElementFactory *factory;
/* create an elementfactory for the qcamsrcparse element */
factory = gst_element_factory_new("qcamsrc",GST_TYPE_QCAMSRC,
&gst_qcamsrc_details);
g_return_val_if_fail(factory != NULL, FALSE);
gst_element_factory_add_pad_template (factory,
GST_PAD_TEMPLATE_GET (gst_qcamsrc_src_factory));
gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
if (!gst_element_register (plugin, "qcamsrc", GST_RANK_NONE, GST_TYPE_QCAMSRC))
return FALSE;
return TRUE;
}
GstPluginDesc plugin_desc = {
GST_PLUGIN_DEFINE (
GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"qcamsrc",
plugin_init
};
"Read from a QuickCam device",
plugin_init,
VERSION,
GST_LICENSE,
GST_COPYRIGHT,
GST_PACKAGE,
GST_ORIGIN
)
......@@ -37,15 +37,12 @@
#include <vcdsrc.h>
static GstElementDetails vcdsrc_details = {
static GstElementDetails vcdsrc_details = GST_ELEMENT_DETAILS (
"VCD Source",
"Source/File",
"LGPL",
"Asynchronous read from VCD disk",
VERSION,
"Erik Walthinsen <omega@cse.ogi.edu>",
"(C) 1999",
};
"Erik Walthinsen <omega@cse.ogi.edu>"
);
/* VCDSrc signals and args */
......@@ -63,6 +60,7 @@ enum {
ARG_MAX_ERRORS,
};
static void vcdsrc_base_init (gpointer g_class);
static void vcdsrc_class_init (VCDSrcClass *klass);
static void vcdsrc_init (VCDSrc *vcdsrc);
static void vcdsrc_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
......@@ -85,7 +83,8 @@ vcdsrc_get_type (void)
if (!vcdsrc_type) {
static const GTypeInfo vcdsrc_info = {
sizeof(VCDSrcClass), NULL,
sizeof(VCDSrcClass),
vcdsrc_base_init,
NULL,
(GClassInitFunc)vcdsrc_class_init,
NULL,
......@@ -99,6 +98,13 @@ vcdsrc_get_type (void)
return vcdsrc_type;
}
static void
vcdsrc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_set_details (element_class, &vcdsrc_details);
}
static void
vcdsrc_class_init (VCDSrcClass *klass)
{
......@@ -108,7 +114,7 @@ vcdsrc_class_init (VCDSrcClass *klass)
gobject_class = (GObjectClass*)klass;
gstelement_class = (GstElementClass*)klass;
parent_class = g_type_class_ref(GST_TYPE_ELEMENT);
parent_class = g_type_class_peek_parent (klass);
g_object_class_install_property(G_OBJECT_CLASS(klass), ARG_LOCATION,
g_param_spec_string("location","location","location",
......@@ -391,22 +397,20 @@ vcdsrc_recalculate (VCDSrc *vcdsrc)
}
static gboolean
plugin_init (GModule *module, GstPlugin *plugin)
plugin_init (GstPlugin *plugin)
{
GstElementFactory *factory;
/* create an elementfactory for the vcdsrc element */
factory = gst_element_factory_new("vcdsrc",GST_TYPE_VCDSRC,
&vcdsrc_details);
g_return_val_if_fail(factory != NULL, FALSE);
gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));
return TRUE;
return gst_element_register (plugin, "vcdsrc", GST_RANK_NONE, GST_TYPE_VCDSRC);
}
GstPluginDesc plugin_desc = {
GST_PLUGIN_DEFINE (
GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"vcdsrc",
plugin_init
};
"Asynchronous read from VCD disk",
plugin_init,
VERSION,
GST_LICENSE,
GST_COPYRIGHT,
GST_PACKAGE,
GST_ORIGIN
)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment