GstPadTemplate <-> gst_pad_template <-> GST_PAD_TEMPLATE same with *factory and typefind.

Original commit message from CVS:
GstPadTemplate <-> gst_pad_template <-> GST_PAD_TEMPLATE

same with *factory and typefind.

also, some -Werror fixes.
This commit is contained in:
Andy Wingo 2002-04-11 20:42:25 +00:00
parent f7cf0134f4
commit 675ef5cc8e
2 changed files with 16 additions and 16 deletions

View file

@ -45,7 +45,7 @@ static GstElementDetails gst_lame_details =
"(C) 2000",
};
GST_PADTEMPLATE_FACTORY (gst_lame_sink_factory,
GST_PAD_TEMPLATE_FACTORY (gst_lame_sink_factory,
"sink",
GST_PAD_SINK,
GST_PAD_ALWAYS,
@ -70,7 +70,7 @@ GST_PADTEMPLATE_FACTORY (gst_lame_sink_factory,
)
)
GST_PADTEMPLATE_FACTORY (gst_lame_src_factory,
GST_PAD_TEMPLATE_FACTORY (gst_lame_src_factory,
"src",
GST_PAD_SRC,
GST_PAD_ALWAYS,
@ -391,12 +391,12 @@ gst_lame_init (GstLame *lame)
{
GST_DEBUG_ENTER ("(\"%s\")", gst_element_get_name (GST_ELEMENT (lame)));
lame->sinkpad = gst_pad_new_from_template (GST_PADTEMPLATE_GET (gst_lame_sink_factory), "sink");
lame->sinkpad = gst_pad_new_from_template (GST_PAD_TEMPLATE_GET (gst_lame_sink_factory), "sink");
gst_element_add_pad (GST_ELEMENT (lame), lame->sinkpad);
gst_pad_set_chain_function (lame->sinkpad, gst_lame_chain);
gst_pad_set_connect_function (lame->sinkpad, gst_lame_sinkconnect);
lame->srcpad = gst_pad_new_from_template (GST_PADTEMPLATE_GET (gst_lame_src_factory), "src");
lame->srcpad = gst_pad_new_from_template (GST_PAD_TEMPLATE_GET (gst_lame_src_factory), "src");
gst_element_add_pad (GST_ELEMENT (lame), lame->srcpad);
GST_FLAG_SET (lame, GST_ELEMENT_EVENT_AWARE);
@ -848,17 +848,17 @@ plugin_init (GModule *module, GstPlugin *plugin)
GstElementFactory *factory;
/* create an elementfactory for the gst_lame element */
factory = gst_elementfactory_new ("lame", GST_TYPE_LAME,
factory = gst_element_factory_new ("lame", GST_TYPE_LAME,
&gst_lame_details);
g_return_val_if_fail (factory != NULL, FALSE);
/* register the source's padtemplate */
gst_elementfactory_add_padtemplate (factory,
GST_PADTEMPLATE_GET (gst_lame_src_factory));
gst_element_factory_add_pad_template (factory,
GST_PAD_TEMPLATE_GET (gst_lame_src_factory));
/* register the sink's padtemplate */
gst_elementfactory_add_padtemplate (factory,
GST_PADTEMPLATE_GET (gst_lame_sink_factory));
gst_element_factory_add_pad_template (factory,
GST_PAD_TEMPLATE_GET (gst_lame_sink_factory));
/* and add the gst_lame element factory to the plugin */
gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory));

View file

@ -29,13 +29,13 @@ main (int argc, char *argv[])
gst_init (&argc, &argv);
/* create elements */
if (!(pipeline = gst_elementfactory_make ("pipeline", "pipeline"))) return 1;
if (!(src = gst_elementfactory_make ("fakesrc", "source"))) return 1;
if (!(tee = gst_elementfactory_make ("tee", "tee"))) return 1;
if (!(encoder1 = gst_elementfactory_make ("lame", "lame1"))) return 1;
if (!(encoder2 = gst_elementfactory_make ("lame", "lame2"))) return 1;
if (!(sink1 = gst_elementfactory_make ("fakesink", "sink1"))) return 1;
if (!(sink2 = gst_elementfactory_make ("fakesink", "sink2"))) return 1;
if (!(pipeline = gst_element_factory_make ("pipeline", "pipeline"))) return 1;
if (!(src = gst_element_factory_make ("fakesrc", "source"))) return 1;
if (!(tee = gst_element_factory_make ("tee", "tee"))) return 1;
if (!(encoder1 = gst_element_factory_make ("lame", "lame1"))) return 1;
if (!(encoder2 = gst_element_factory_make ("lame", "lame2"))) return 1;
if (!(sink1 = gst_element_factory_make ("fakesink", "sink1"))) return 1;
if (!(sink2 = gst_element_factory_make ("fakesink", "sink2"))) return 1;
pipeline = gst_pipeline_new ("pipeline");
g_signal_connect (pipeline, "error", G_CALLBACK (error_callback), NULL);