summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohan Rydberg <jrydberg@gnu.org>2006-04-20 19:59:34 +0000
committerStefan Kost <ensonic@users.sourceforge.net>2006-04-20 19:59:34 +0000
commitf341ef39fafdd40641ee83e4c487651baf48bffe (patch)
treebf5eec87e1510f0ee8a437289ceebdd6c60a839c
parent3291b9650897ec066d42fe087876150b50e386f5 (diff)
remove double gst_get_, fix '_' in names
Original commit message from CVS: Patch by: Johan Rydberg <jrydberg@gnu.org> * src/gstplugin.c: (gst_plugin_template_get_type), (gst_plugin_template_base_init), (gst_plugin_template_class_init), (gst_plugin_template_set_property), (gst_plugin_template_get_property): * src/gstplugin.h: * src/gsttransform.c: (gst_plugin_template_base_init), (gst_plugin_template_set_property), (gst_plugin_template_get_property): * tools/make_element: remove double gst_get_, fix '_' in names
m---------common0
-rw-r--r--gst-plugin/ChangeLog16
-rw-r--r--gst-plugin/src/gstplugin.c16
-rw-r--r--gst-plugin/src/gstplugin.h4
-rw-r--r--gst-plugin/src/gsttransform.c21
-rwxr-xr-xgst-plugin/tools/make_element8
6 files changed, 35 insertions, 30 deletions
diff --git a/common b/common
-Subproject c09cd18d328f740ac532377fa5605b0f712cc6f
+Subproject a6710e67fd82147e32a18f1b63177583faffd49
diff --git a/gst-plugin/ChangeLog b/gst-plugin/ChangeLog
index ef16383..7daf379 100644
--- a/gst-plugin/ChangeLog
+++ b/gst-plugin/ChangeLog
@@ -1,3 +1,19 @@
+2006-04-20 Stefan Kost <ensonic@users.sf.net>
+
+ Patch by: Johan Rydberg <jrydberg@gnu.org>
+
+ * src/gstplugin.c: (gst_plugin_template_get_type),
+ (gst_plugin_template_base_init), (gst_plugin_template_class_init),
+ (gst_plugin_template_set_property),
+ (gst_plugin_template_get_property):
+ * src/gstplugin.h:
+ * src/gsttransform.c: (gst_plugin_template_base_init),
+ (gst_plugin_template_set_property),
+ (gst_plugin_template_get_property):
+ * tools/make_element:
+ remove double gst_get_, fix '_' in names
+
+
2006-02-26 Tim-Philipp Müller <tim at centricular dot net>
* src/gstplugin.c: (gst_plugin_template_init),
diff --git a/gst-plugin/src/gstplugin.c b/gst-plugin/src/gstplugin.c
index 1f23b57..b7eb059 100644
--- a/gst-plugin/src/gstplugin.c
+++ b/gst-plugin/src/gstplugin.c
@@ -108,7 +108,7 @@ static GstFlowReturn gst_plugin_template_chain (GstPad *pad, GstBuffer *buf);
static GstElementClass *parent_class = NULL;
GType
-gst_gst_plugin_template_get_type (void)
+gst_plugin_template_get_type (void)
{
static GType plugin_type = 0;
@@ -139,7 +139,7 @@ gst_plugin_template_base_init (GstPluginTemplateClass *klass)
static GstElementDetails element_details = {
"PluginTemplate",
"Generic/PluginTemplate",
- "Generic Template Plugin",
+ "Generic Template Element",
"Thomas Vander Stichele <thomas@apestaart.org>"
};
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
@@ -161,7 +161,7 @@ gst_plugin_template_class_init (GstPluginTemplateClass *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);
gobject_class->set_property = gst_plugin_template_set_property;
gobject_class->get_property = gst_plugin_template_get_property;
@@ -201,10 +201,7 @@ static void
gst_plugin_template_set_property (GObject *object, guint prop_id,
const GValue *value, GParamSpec *pspec)
{
- GstPluginTemplate *filter;
-
- g_return_if_fail (GST_IS_PLUGIN_TEMPLATE (object));
- filter = GST_PLUGIN_TEMPLATE (object);
+ GstPluginTemplate *filter = GST_PLUGIN_TEMPLATE (object);
switch (prop_id)
{
@@ -221,10 +218,7 @@ static void
gst_plugin_template_get_property (GObject *object, guint prop_id,
GValue *value, GParamSpec *pspec)
{
- GstPluginTemplate *filter;
-
- g_return_if_fail (GST_IS_PLUGIN_TEMPLATE (object));
- filter = GST_PLUGIN_TEMPLATE (object);
+ GstPluginTemplate *filter = GST_PLUGIN_TEMPLATE (object);
switch (prop_id) {
case ARG_SILENT:
diff --git a/gst-plugin/src/gstplugin.h b/gst-plugin/src/gstplugin.h
index 0ef9256..1bcdb90 100644
--- a/gst-plugin/src/gstplugin.h
+++ b/gst-plugin/src/gstplugin.h
@@ -51,7 +51,7 @@ G_BEGIN_DECLS
/* #defines don't like whitespacey bits */
#define GST_TYPE_PLUGIN_TEMPLATE \
- (gst_gst_plugin_template_get_type())
+ (gst_plugin_template_get_type())
#define GST_PLUGIN_TEMPLATE(obj) \
(G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_PLUGIN_TEMPLATE,GstPluginTemplate))
#define GST_PLUGIN_TEMPLATE_CLASS(klass) \
@@ -78,7 +78,7 @@ struct _GstPluginTemplateClass
GstElementClass parent_class;
};
-GType gst_gst_plugin_template_get_type (void);
+GType gst_plugin_template_get_type (void);
G_END_DECLS
diff --git a/gst-plugin/src/gsttransform.c b/gst-plugin/src/gsttransform.c
index 64c595d..4756f8c 100644
--- a/gst-plugin/src/gsttransform.c
+++ b/gst-plugin/src/gsttransform.c
@@ -35,15 +35,14 @@
#include "config.h"
#endif
-#include <string.h>
#include <gst/gst.h>
#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
#include <gst/controller/gstcontroller.h>
#include "gstplugin.h"
-GST_DEBUG_CATEGORY (plugin_debug);
+GST_DEBUG_CATEGORY_STATIC (gst_plugin_template_debug);
+#define GST_CAT_DEFAULT gst_plugin_template_debug
/* Filter signals and args */
enum {
@@ -73,7 +72,7 @@ GST_STATIC_PAD_TEMPLATE (
);
#define DEBUG_INIT(bla) \
- GST_DEBUG_CATEGORY_INIT (plugin_debug, "plugin", 0, "plugin template element");
+ GST_DEBUG_CATEGORY_INIT (gst_plugin_template_debug, "plugin_template", 0, "transformer template plugin");
GST_BOILERPLATE_FULL (GstPluginTemplate, gst_plugin_template, GstBaseTransform,
GST_TYPE_BASE_TRANSFORM, DEBUG_INIT);
@@ -94,7 +93,7 @@ gst_plugin_template_base_init (gpointer klass)
static GstElementDetails element_details = {
"PluginTemplate",
"Generic/PluginTemplate",
- "Generic Template Plugin",
+ "Generic Template Element",
"Stefan Kost <ensonic@users.sf.net>"
};
GstElementClass *element_class = GST_ELEMENT_CLASS (klass);
@@ -133,10 +132,7 @@ static void
gst_plugin_template_set_property (GObject * object, guint prop_id,
const GValue * value, GParamSpec * pspec)
{
- GstPluginTemplate *filter;
-
- g_return_if_fail (GST_IS_PLUGIN_TEMPLATE (object));
- filter = GST_PLUGIN_TEMPLATE (object);
+ GstPluginTemplate *filter = GST_PLUGIN_TEMPLATE (object);
switch (prop_id) {
case PROP_SILENT:
@@ -152,10 +148,7 @@ static void
gst_plugin_template_get_property (GObject * object, guint prop_id,
GValue * value, GParamSpec * pspec)
{
- GstPluginTemplate *filter;
-
- g_return_if_fail (GST_IS_PLUGIN_TEMPLATE (object));
- filter = GST_PLUGIN_TEMPLATE (object);
+ GstPluginTemplate *filter = GST_PLUGIN_TEMPLATE (object);
switch (prop_id) {
case PROP_SILENT:
@@ -212,7 +205,7 @@ GST_PLUGIN_DEFINE (
GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"plugin",
- "Template plugin",
+ "Generic Template Plugin",
plugin_init,
VERSION,
"LGPL",
diff --git a/gst-plugin/tools/make_element b/gst-plugin/tools/make_element
index 4447185..c83e4c4 100755
--- a/gst-plugin/tools/make_element
+++ b/gst-plugin/tools/make_element
@@ -21,11 +21,13 @@ id=$(echo '$Id$' | sed \
TEMPLATE=$(echo $Template | tr a-z A-Z)
template=$(echo $Template | tr A-Z a-z)
+filename=$(echo $template | tr -d _)
+Template=$(echo $Template | tr -d _)
# remember to break up the Id: in the line below
sed \
-e 's/gstplugin\.c/SOURCEFILE/g' \
- -e "s/gstplugin\.h/gst$template.h/g" \
+ -e "s/gstplugin\.h/gst$filename.h/g" \
-e "s/GstPluginTemplate/Gst$Template/g" \
-e "s/gst_plugin_template/gst_$template/g" \
-e "s/gst_type_plugin_template/gst_$template/g" \
@@ -34,7 +36,7 @@ sed \
-e 's/\$I[d]: \([^$]*\)\$/\1/g' \
-e 's/SOURCEFILE/gstobject\.c/g' \
-e "s%MAKEFILTERVERSION%$id%g" \
- $srcfile >gst$template.c.tmp && mv gst$template.c.tmp gst$template.c
+ $srcfile >gst$filename.c.tmp && mv gst$filename.c.tmp gst$filename.c
sed \
-e 's/gstplugin\.c/SOURCEFILE/g' \
@@ -46,5 +48,5 @@ sed \
-e 's/\$I[d]: \([^$]*\)\$/\1/g' \
-e 's/SOURCEFILE/gstobject\.c/g' \
-e "s%MAKEFILTERVERSION%$id%g" \
- $srcfile_h >gst$template.h.tmp && mv gst$template.h.tmp gst$template.h
+ $srcfile_h >gst$filename.h.tmp && mv gst$filename.h.tmp gst$filename.h