[gegl] remove useless pad properties



commit c17a7fae9719252271e39a97c089ba610584b64f
Author: Daniel Sabo <DanielSabo gmail com>
Date:   Thu Jun 20 23:24:13 2013 -0700

    remove useless pad properties
    
    They were only ever used for their ParamSpec objects.

 gegl/graph/gegl-pad.c                     |   17 ++++-
 gegl/operation/gegl-operation-composer.c  |  101 +++++++-----------------
 gegl/operation/gegl-operation-composer3.c |  123 +++++++++--------------------
 gegl/operation/gegl-operation-filter.c    |  110 +++++---------------------
 gegl/operation/gegl-operation-meta.c      |   33 --------
 gegl/operation/gegl-operation-sink.c      |   61 +++------------
 gegl/operation/gegl-operation-source.c    |   60 +++------------
 7 files changed, 124 insertions(+), 381 deletions(-)
---
diff --git a/gegl/graph/gegl-pad.c b/gegl/graph/gegl-pad.c
index 078bf28..8b978fc 100644
--- a/gegl/graph/gegl-pad.c
+++ b/gegl/graph/gegl-pad.c
@@ -81,8 +81,17 @@ finalize (GObject *gobject)
 
   g_assert (self->connections == NULL);
 
+  if (self->param_spec)
+    {
+      g_param_spec_unref (self->param_spec);
+      self->param_spec = NULL;
+    }
+
   if (self->name)
-    g_free (self->name);
+    {
+      g_free (self->name);
+      self->name = NULL;
+    }
 
   G_OBJECT_CLASS (gegl_pad_parent_class)->finalize (gobject);
 }
@@ -101,7 +110,11 @@ gegl_pad_set_param_spec (GeglPad    *self,
 {
   g_return_if_fail (GEGL_IS_PAD (self));
 
-  self->param_spec = param_spec;
+  if (self->param_spec)
+    g_param_spec_unref (self->param_spec);
+
+  self->param_spec = g_param_spec_ref (param_spec);
+
   gegl_pad_set_name (self, g_param_spec_get_name (param_spec));
 }
 
diff --git a/gegl/operation/gegl-operation-composer.c b/gegl/operation/gegl-operation-composer.c
index 49c72d9..7f69583 100644
--- a/gegl/operation/gegl-operation-composer.c
+++ b/gegl/operation/gegl-operation-composer.c
@@ -31,22 +31,6 @@
 #include "buffer/gegl-region.h"
 #include "buffer/gegl-buffer.h"
 
-enum
-{
-  PROP_0,
-  PROP_OUTPUT,
-  PROP_INPUT,
-  PROP_AUX
-};
-
-static void     get_property (GObject             *gobject,
-                              guint                prop_id,
-                              GValue              *value,
-                              GParamSpec          *pspec);
-static void     set_property (GObject             *gobject,
-                              guint                prop_id,
-                              const GValue        *value,
-                              GParamSpec          *pspec);
 static gboolean gegl_operation_composer_process (GeglOperation       *operation,
                               GeglOperationContext     *context,
                               const gchar         *output_prop,
@@ -69,41 +53,13 @@ G_DEFINE_TYPE (GeglOperationComposer, gegl_operation_composer,
 static void
 gegl_operation_composer_class_init (GeglOperationComposerClass * klass)
 {
-  GObjectClass       *object_class    = G_OBJECT_CLASS (klass);
   GeglOperationClass *operation_class = GEGL_OPERATION_CLASS (klass);
 
-  object_class->set_property = set_property;
-  object_class->get_property = get_property;
-
   operation_class->process = gegl_operation_composer_process;
   operation_class->attach = attach;
   operation_class->detect = detect;
   operation_class->get_bounding_box = get_bounding_box;
   operation_class->get_required_for_output = get_required_for_output;
-
-  g_object_class_install_property (object_class, PROP_OUTPUT,
-                                   g_param_spec_object ("output",
-                                                        "Output",
-                                                        "Output pad for generated image buffer.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READABLE |
-                                                        GEGL_PARAM_PAD_OUTPUT));
-
-  g_object_class_install_property (object_class, PROP_INPUT,
-                                   g_param_spec_object ("input",
-                                                        "Input",
-                                                        "Input pad, for image buffer input.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
-
-  g_object_class_install_property (object_class, PROP_AUX,
-                                   g_param_spec_object ("aux",
-                                                        "Input",
-                                                        "Auxiliary image buffer input pad.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
 }
 
 static void
@@ -114,34 +70,35 @@ gegl_operation_composer_init (GeglOperationComposer *self)
 static void
 attach (GeglOperation *self)
 {
-  GeglOperation *operation    = GEGL_OPERATION (self);
-  GObjectClass  *object_class = G_OBJECT_GET_CLASS (self);
-
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "output"));
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "input"));
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "aux"));
-}
-
-static void
-get_property (GObject    *object,
-              guint       prop_id,
-              GValue     *value,
-              GParamSpec *pspec)
-{
-}
-
-static void
-set_property (GObject      *object,
-              guint         prop_id,
-              const GValue *value,
-              GParamSpec   *pspec)
-{
+  GeglOperation *operation = GEGL_OPERATION (self);
+  GParamSpec    *pspec;
+
+  pspec = g_param_spec_object ("output",
+                               "Output",
+                               "Output pad for generated image buffer.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READABLE |
+                               GEGL_PARAM_PAD_OUTPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
+
+  pspec = g_param_spec_object ("input",
+                               "Input",
+                               "Input pad, for image buffer input.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
+
+  pspec = g_param_spec_object ("aux",
+                               "Aux",
+                               "Auxiliary image buffer input pad.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
 }
 
 static gboolean
diff --git a/gegl/operation/gegl-operation-composer3.c b/gegl/operation/gegl-operation-composer3.c
index 5bf50d1..09ff63a 100644
--- a/gegl/operation/gegl-operation-composer3.c
+++ b/gegl/operation/gegl-operation-composer3.c
@@ -31,23 +31,6 @@
 #include "buffer/gegl-region.h"
 #include "buffer/gegl-buffer.h"
 
-enum
-{
-  PROP_0,
-  PROP_OUTPUT,
-  PROP_INPUT,
-  PROP_AUX,
-  PROP_AUX2
-};
-
-static void     get_property (GObject              *gobject,
-                              guint                 prop_id,
-                              GValue               *value,
-                              GParamSpec           *pspec);
-static void     set_property (GObject              *gobject,
-                              guint                 prop_id,
-                              const GValue         *value,
-                              GParamSpec           *pspec);
 static gboolean gegl_operation_composer3_process
                              (GeglOperation        *operation,
                               GeglOperationContext *context,
@@ -71,49 +54,13 @@ G_DEFINE_TYPE (GeglOperationComposer3, gegl_operation_composer3,
 static void
 gegl_operation_composer3_class_init (GeglOperationComposer3Class * klass)
 {
-  GObjectClass       *object_class    = G_OBJECT_CLASS (klass);
   GeglOperationClass *operation_class = GEGL_OPERATION_CLASS (klass);
 
-  object_class->set_property = set_property;
-  object_class->get_property = get_property;
-
   operation_class->process = gegl_operation_composer3_process;
   operation_class->attach = attach;
   operation_class->detect = detect;
   operation_class->get_bounding_box = get_bounding_box;
   operation_class->get_required_for_output = get_required_for_output;
-
-  g_object_class_install_property (object_class, PROP_OUTPUT,
-                                   g_param_spec_object ("output",
-                                                        "Output",
-                                                        "Output pad for generated image buffer.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READABLE |
-                                                        GEGL_PARAM_PAD_OUTPUT));
-
-  g_object_class_install_property (object_class, PROP_INPUT,
-                                   g_param_spec_object ("input",
-                                                        "Input",
-                                                        "Input pad, for image buffer input.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
-
-  g_object_class_install_property (object_class, PROP_AUX,
-                                   g_param_spec_object ("aux",
-                                                        "Input",
-                                                        "Auxiliary image buffer input pad.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
-
-  g_object_class_install_property (object_class, PROP_AUX2,
-                                   g_param_spec_object ("aux2",
-                                                        "Input",
-                                                        "Second auxiliary image buffer input pad.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
 }
 
 static void
@@ -124,38 +71,44 @@ gegl_operation_composer3_init (GeglOperationComposer3 *self)
 static void
 attach (GeglOperation *self)
 {
-  GeglOperation *operation    = GEGL_OPERATION (self);
-  GObjectClass  *object_class = G_OBJECT_GET_CLASS (self);
-
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "output"));
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "input"));
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "aux"));
-
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "aux2"));
-}
-
-static void
-get_property (GObject    *object,
-              guint       prop_id,
-              GValue     *value,
-              GParamSpec *pspec)
-{
-}
-
-static void
-set_property (GObject      *object,
-              guint         prop_id,
-              const GValue *value,
-              GParamSpec   *pspec)
-{
+  GeglOperation *operation = GEGL_OPERATION (self);
+  GParamSpec    *pspec;
+
+  pspec = g_param_spec_object ("output",
+                               "Output",
+                               "Output pad for generated image buffer.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READABLE |
+                               GEGL_PARAM_PAD_OUTPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
+
+  pspec = g_param_spec_object ("input",
+                               "Input",
+                               "Input pad, for image buffer input.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
+
+  pspec = g_param_spec_object ("aux",
+                               "Aux",
+                               "Auxiliary image buffer input pad.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
+
+  pspec = g_param_spec_object ("aux2",
+                               "Aux2",
+                               "Second auxiliary image buffer input pad.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
 }
 
 static gboolean
diff --git a/gegl/operation/gegl-operation-filter.c b/gegl/operation/gegl-operation-filter.c
index c9b1766..5c801d9 100644
--- a/gegl/operation/gegl-operation-filter.c
+++ b/gegl/operation/gegl-operation-filter.c
@@ -31,23 +31,6 @@
 #include "buffer/gegl-region.h"
 #include "buffer/gegl-buffer.h"
 
-enum
-{
-  PROP_0,
-  PROP_OUTPUT,
-  PROP_INPUT
-};
-
-static void     get_property          (GObject       *gobject,
-                                       guint          prop_id,
-                                       GValue        *value,
-                                       GParamSpec    *pspec);
-
-static void     set_property          (GObject       *gobject,
-                                       guint          prop_id,
-                                       const GValue  *value,
-                                       GParamSpec    *pspec);
-
 static gboolean gegl_operation_filter_process
                                       (GeglOperation        *operation,
                                        GeglOperationContext *context,
@@ -72,33 +55,13 @@ G_DEFINE_TYPE (GeglOperationFilter, gegl_operation_filter, GEGL_TYPE_OPERATION)
 static void
 gegl_operation_filter_class_init (GeglOperationFilterClass * klass)
 {
-  GObjectClass       *object_class    = G_OBJECT_CLASS (klass);
   GeglOperationClass *operation_class = GEGL_OPERATION_CLASS (klass);
 
-  object_class->set_property = set_property;
-  object_class->get_property = get_property;
-
   operation_class->process                 = gegl_operation_filter_process;
   operation_class->attach                  = attach;
   operation_class->detect                  = detect;
   operation_class->get_bounding_box        = get_bounding_box;
   operation_class->get_required_for_output = get_required_for_output;
-
-  g_object_class_install_property (object_class, PROP_OUTPUT,
-                                   g_param_spec_object ("output",
-                                                        "Output",
-                                                        "Output pad for generated image buffer.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READABLE |
-                                                        GEGL_PARAM_PAD_OUTPUT));
-
-  g_object_class_install_property (object_class, PROP_INPUT,
-                                   g_param_spec_object ("input",
-                                                        "Input",
-                                                        "Input pad, for image buffer input.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
 }
 
 static void
@@ -109,15 +72,26 @@ gegl_operation_filter_init (GeglOperationFilter *self)
 static void
 attach (GeglOperation *self)
 {
-  GeglOperation *operation    = GEGL_OPERATION (self);
-  GObjectClass  *object_class = G_OBJECT_GET_CLASS (self);
-
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "output"));
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "input"));
+  GeglOperation *operation = GEGL_OPERATION (self);
+  GParamSpec    *pspec;
+
+  pspec = g_param_spec_object ("output",
+                               "Output",
+                               "Output pad for generated image buffer.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READABLE |
+                               GEGL_PARAM_PAD_OUTPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
+
+  pspec = g_param_spec_object ("input",
+                               "Input",
+                               "Input pad, for image buffer input.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
 }
 
 
@@ -135,50 +109,6 @@ detect (GeglOperation *operation,
   return operation->node;
 }
 
-
-void babl_backtrack (void);
-
-static void
-get_property (GObject    *object,
-              guint       prop_id,
-              GValue     *value,
-              GParamSpec *pspec)
-{
-  switch (prop_id)
-    {
-      case PROP_OUTPUT:
-        g_warning ("shouldn't happen");
-        babl_backtrack ();
-        break;
-
-      case PROP_INPUT:
-        g_warning ("shouldn't happen");
-        babl_backtrack ();
-        break;
-
-      default:
-        break;
-    }
-}
-
-static void
-set_property (GObject      *object,
-              guint         prop_id,
-              const GValue *value,
-              GParamSpec   *pspec)
-{
-  switch (prop_id)
-    {
-      case PROP_INPUT:
-        g_warning ("shouldn't happen");
-        babl_backtrack ();
-        break;
-
-      default:
-        break;
-    }
-}
-
 static gboolean
 gegl_operation_filter_process (GeglOperation        *operation,
                                GeglOperationContext *context,
diff --git a/gegl/operation/gegl-operation-meta.c b/gegl/operation/gegl-operation-meta.c
index d8e1c84..0ef17ec 100644
--- a/gegl/operation/gegl-operation-meta.c
+++ b/gegl/operation/gegl-operation-meta.c
@@ -26,21 +26,6 @@
 #include "graph/gegl-node.h"
 #include <string.h>
 
-
-enum
-{
-  PROP_0,
-  PROP_LAST
-};
-
-static void       get_property (GObject       *gobject,
-                                guint          prop_id,
-                                GValue        *value,
-                                GParamSpec    *pspec);
-static void       set_property (GObject       *gobject,
-                                guint          prop_id,
-                                const GValue  *value,
-                                GParamSpec    *pspec);
 static void       finalize     (GObject       *self_object);
 static GeglNode * detect       (GeglOperation *operation,
                                 gint           x,
@@ -55,8 +40,6 @@ gegl_operation_meta_class_init (GeglOperationMetaClass *klass)
 {
   GObjectClass *object_class = G_OBJECT_CLASS (klass);
 
-  object_class->set_property           = set_property;
-  object_class->get_property           = get_property;
   object_class->finalize               = finalize;
   GEGL_OPERATION_CLASS (klass)->detect = detect;
 }
@@ -67,22 +50,6 @@ gegl_operation_meta_init (GeglOperationMeta *self)
   self->redirects = NULL;
 }
 
-static void
-get_property (GObject    *object,
-              guint       prop_id,
-              GValue     *value,
-              GParamSpec *pspec)
-{
-}
-
-static void
-set_property (GObject      *object,
-              guint         prop_id,
-              const GValue *value,
-              GParamSpec   *pspec)
-{
-}
-
 static GeglNode *
 detect (GeglOperation *operation,
         gint           x,
diff --git a/gegl/operation/gegl-operation-sink.c b/gegl/operation/gegl-operation-sink.c
index c3cca12..8154005 100644
--- a/gegl/operation/gegl-operation-sink.c
+++ b/gegl/operation/gegl-operation-sink.c
@@ -28,22 +28,6 @@
 #include "graph/gegl-node.h"
 #include "graph/gegl-pad.h"
 
-
-enum
-{
-  PROP_0,
-  PROP_INPUT
-};
-
-
-static void          gegl_operation_sink_get_property            (GObject              *gobject,
-                                                                  guint                 prop_id,
-                                                                  GValue               *value,
-                                                                  GParamSpec           *pspec);
-static void          gegl_operation_sink_set_property            (GObject              *gobject,
-                                                                  guint                 prop_id,
-                                                                  const GValue         *value,
-                                                                  GParamSpec           *pspec);
 static gboolean      gegl_operation_sink_process                 (GeglOperation        *operation,
                                                                   GeglOperationContext *context,
                                                                   const gchar          *output_prop,
@@ -62,26 +46,14 @@ G_DEFINE_TYPE (GeglOperationSink, gegl_operation_sink, GEGL_TYPE_OPERATION)
 static void
 gegl_operation_sink_class_init (GeglOperationSinkClass * klass)
 {
-  GObjectClass       *object_class    = G_OBJECT_CLASS (klass);
   GeglOperationClass *operation_class = GEGL_OPERATION_CLASS (klass);
 
   klass->needs_full = FALSE;
 
-  object_class->set_property = gegl_operation_sink_set_property;
-  object_class->get_property = gegl_operation_sink_get_property;
-
   operation_class->process                 = gegl_operation_sink_process;
   operation_class->attach                  = gegl_operation_sink_attach;
   operation_class->get_bounding_box        = gegl_operation_sink_get_bounding_box;
   operation_class->get_required_for_output = gegl_operation_sink_get_required_for_output;
-
-  g_object_class_install_property (object_class, PROP_INPUT,
-                                   g_param_spec_object ("input",
-                                                        "Input",
-                                                        "Input pad, for image buffer input.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READWRITE |
-                                                        GEGL_PARAM_PAD_INPUT));
 }
 
 static void
@@ -92,28 +64,17 @@ gegl_operation_sink_init (GeglOperationSink *self)
 static void
 gegl_operation_sink_attach (GeglOperation *self)
 {
-  GeglOperation *operation    = GEGL_OPERATION (self);
-  GObjectClass  *object_class = G_OBJECT_GET_CLASS (self);
-
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "input"));
-}
-
-static void
-gegl_operation_sink_get_property (GObject    *object,
-                                  guint       prop_id,
-                                  GValue     *value,
-                                  GParamSpec *pspec)
-{
-}
-
-static void
-gegl_operation_sink_set_property (GObject      *object,
-                                  guint         prop_id,
-                                  const GValue *value,
-                                  GParamSpec   *pspec)
-{
+  GeglOperation *operation = GEGL_OPERATION (self);
+  GParamSpec    *pspec;
+
+  pspec = g_param_spec_object ("input",
+                               "Input",
+                               "Input pad, for image buffer input.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READWRITE |
+                               GEGL_PARAM_PAD_INPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
 }
 
 static gboolean
diff --git a/gegl/operation/gegl-operation-source.c b/gegl/operation/gegl-operation-source.c
index d2a532a..c4e01c2 100644
--- a/gegl/operation/gegl-operation-source.c
+++ b/gegl/operation/gegl-operation-source.c
@@ -28,21 +28,6 @@
 #include "graph/gegl-node.h"
 #include "graph/gegl-pad.h"
 
-enum
-{
-  PROP_0,
-  PROP_OUTPUT,
-  PROP_LAST
-};
-
-static void     get_property (GObject      *gobject,
-                              guint         prop_id,
-                              GValue       *value,
-                              GParamSpec   *pspec);
-static void     set_property (GObject      *gobject,
-                              guint         prop_id,
-                              const GValue *value,
-                              GParamSpec   *pspec);
 static gboolean gegl_operation_source_process
                              (GeglOperation        *operation,
                               GeglOperationContext *context,
@@ -66,26 +51,14 @@ static GeglRectangle  get_cached_region        (GeglOperation       *operation,
 static void
 gegl_operation_source_class_init (GeglOperationSourceClass * klass)
 {
-  GObjectClass       *gobject_class   = G_OBJECT_CLASS (klass);
   GeglOperationClass *operation_class = GEGL_OPERATION_CLASS (klass);
 
-  gobject_class->set_property = set_property;
-  gobject_class->get_property = get_property;
-
   operation_class->process = gegl_operation_source_process;
   operation_class->attach  = attach;
   operation_class->get_cached_region = get_cached_region;
 
   operation_class->get_bounding_box  = get_bounding_box;
   operation_class->get_required_for_output = get_required_for_output;
-
-  g_object_class_install_property (gobject_class, PROP_OUTPUT,
-                                   g_param_spec_object ("output",
-                                                        "Output",
-                                                        "Output pad for generated image buffer.",
-                                                        GEGL_TYPE_BUFFER,
-                                                        G_PARAM_READABLE |
-                                                        GEGL_PARAM_PAD_OUTPUT));
 }
 
 static void
@@ -96,28 +69,17 @@ gegl_operation_source_init (GeglOperationSource *self)
 static void
 attach (GeglOperation *self)
 {
-  GeglOperation *operation    = GEGL_OPERATION (self);
-  GObjectClass  *object_class = G_OBJECT_GET_CLASS (self);
-
-  gegl_operation_create_pad (operation,
-                             g_object_class_find_property (object_class,
-                                                           "output"));
-}
-
-static void
-get_property (GObject    *object,
-              guint       prop_id,
-              GValue     *value,
-              GParamSpec *pspec)
-{
-}
-
-static void
-set_property (GObject      *object,
-              guint         prop_id,
-              const GValue *value,
-              GParamSpec   *pspec)
-{
+  GeglOperation *operation = GEGL_OPERATION (self);
+  GParamSpec    *pspec;
+
+  pspec = g_param_spec_object ("output",
+                               "Output",
+                               "Output pad for generated image buffer.",
+                               GEGL_TYPE_BUFFER,
+                               G_PARAM_READABLE |
+                               GEGL_PARAM_PAD_OUTPUT);
+  gegl_operation_create_pad (operation, pspec);
+  g_param_spec_sink (pspec);
 }
 
 static gboolean


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]