Commit c940d3f6 authored by Øyvind Kolås's avatar Øyvind Kolås

renamed GeglNodeContext GeglOperation context and replaced the node

field with an operation field.
* gegl/gegl-plugin.h:
* gegl/gegl-types.h:
* gegl/graph/Makefile.am:
* gegl/graph/gegl-node-context.c:
* gegl/graph/gegl-node-context.h:
* gegl/graph/gegl-node.c: 
* gegl/graph/gegl-node.h:
* gegl/graph/gegl-operation-context.c:
* gegl/graph/gegl-operation-context.h:
* gegl/operation/gegl-operation-composer.c:
* gegl/operation/gegl-operation-filter.c:
* gegl/operation/gegl-operation-point-composer.c:
* gegl/operation/gegl-operation-sink.c:
* gegl/operation/gegl-operation-source.c:
* gegl/operation/gegl-operation.c:
* gegl/operation/gegl-operation.h:
* gegl/operation/gegl-operations.c:
* gegl/process/gegl-cr-visitor.c:
* gegl/process/gegl-debug-rect-visitor.c:
* gegl/process/gegl-eval-mgr.c:
* gegl/process/gegl-eval-visitor.c:
* gegl/process/gegl-processor.c:
* operations/common/introspect.c:
* operations/common/load-buffer.c:
* operations/common/magick-load.c:
* operations/common/open-buffer.c:
* operations/common/raw-load.c:
* operations/common/remap.c:
* operations/core/clone.c:
* operations/core/crop.c:
* operations/core/nop.c:
* operations/core/shift.c:
* operations/workshop/rawbayer-load.c:

svn path=/trunk/; revision=2471
parent 9f6f21c0
2008-06-15 Øyvind Kolås <pippin@gimp.org>
renamed GeglNodeContext GeglOperation context and replaced the node
field with an operation field.
* gegl/gegl-plugin.h:
* gegl/gegl-types.h:
* gegl/graph/Makefile.am:
* gegl/graph/gegl-node-context.c:
* gegl/graph/gegl-node-context.h:
* gegl/graph/gegl-node.c:
* gegl/graph/gegl-node.h:
* gegl/graph/gegl-operation-context.c:
* gegl/graph/gegl-operation-context.h:
* gegl/operation/gegl-operation-composer.c:
* gegl/operation/gegl-operation-filter.c:
* gegl/operation/gegl-operation-point-composer.c:
* gegl/operation/gegl-operation-sink.c:
* gegl/operation/gegl-operation-source.c:
* gegl/operation/gegl-operation.c:
* gegl/operation/gegl-operation.h:
* gegl/operation/gegl-operations.c:
* gegl/process/gegl-cr-visitor.c:
* gegl/process/gegl-debug-rect-visitor.c:
* gegl/process/gegl-eval-mgr.c:
* gegl/process/gegl-eval-visitor.c:
* gegl/process/gegl-processor.c:
* operations/common/introspect.c:
* operations/common/load-buffer.c:
* operations/common/magick-load.c:
* operations/common/open-buffer.c:
* operations/common/raw-load.c:
* operations/common/remap.c:
* operations/core/clone.c:
* operations/core/crop.c:
* operations/core/nop.c:
* operations/core/shift.c:
* operations/workshop/rawbayer-load.c:
2008-06-15 Øyvind Kolås <pippin@gimp.org>
* gegl/Makefile.am: do not install gegl-config.c as if it was a
......
This diff is collapsed.
......@@ -56,7 +56,7 @@ typedef struct _GeglNeedVisitor GeglNeedVisitor;
#ifndef __GEGL_PLUGIN_H__
typedef struct _GeglPad GeglPad;
typedef struct _GeglOperation GeglOperation;
typedef struct _GeglNodeContext GeglNodeContext;
typedef struct _GeglOperationContext GeglOperationContext;
typedef struct _GeglConnection GeglConnection;
#endif
typedef struct _GeglPrepareVisitor GeglPrepareVisitor;
......
......@@ -3,7 +3,7 @@ noinst_LTLIBRARIES = libgraph.la
GRAPH_sources = \
gegl-connection.c \
gegl-node.c \
gegl-node-context.c \
gegl-operation-context.c \
gegl-pad.c \
gegl-visitor.c \
gegl-visitable.c
......@@ -12,7 +12,7 @@ GRAPH_sources = \
GRAPH_headers = \
gegl-connection.h \
gegl-node.h \
gegl-node-context.h \
gegl-operation-context.h \
gegl-pad.h \
gegl-visitor.h \
gegl-visitable.h
......
......@@ -306,6 +306,9 @@ set_property (GObject *gobject,
* the preceding argument is NULL, gcc might warn about
* use of uninitialized variable.
*/
#if defined(__GNUC__)
null = NULL;
#endif
gegl_node_set_op_class (node, g_value_get_string (value), NULL, null);
}
break;
......@@ -1399,7 +1402,7 @@ gegl_node_set_need_rect (GeglNode *node,
gint width,
gint height)
{
GeglNodeContext *context;
GeglOperationContext *context;
g_return_if_fail (GEGL_IS_NODE (node));
g_return_if_fail (context_id != NULL);
......@@ -1536,7 +1539,7 @@ void
gegl_node_process (GeglNode *self)
{
GeglNode *input;
GeglNodeContext *context;
GeglOperationContext *context;
GeglBuffer *buffer;
GeglRectangle defined;
......@@ -1555,11 +1558,11 @@ gegl_node_process (GeglNode *self)
GValue value = { 0, };
g_value_init (&value, GEGL_TYPE_BUFFER);
g_value_set_object (&value, buffer);
gegl_node_context_set_property (context, "input", &value);
gegl_operation_context_set_property (context, "input", &value);
g_value_unset (&value);
}
gegl_node_context_set_result_rect (context, defined.x, defined.y, defined.width, defined.h);
gegl_operation_context_set_result_rect (context, defined.x, defined.y, defined.width, defined.h);
gegl_operation_process (self->operation, &defined, "foo");
gegl_node_remove_context (self, &defined);
g_object_unref (buffer);
......@@ -1570,7 +1573,7 @@ static gint
lookup_context (gconstpointer a,
gconstpointer context_id)
{
GeglNodeContext *context = (void *) a;
GeglOperationContext *context = (void *) a;
if (context->context_id == context_id)
return 0;
......@@ -1579,12 +1582,12 @@ lookup_context (gconstpointer a,
void babl_backtrack (void);
GeglNodeContext *
GeglOperationContext *
gegl_node_get_context (GeglNode *self,
gpointer context_id)
{
GSList *found;
GeglNodeContext *context = NULL;
GeglOperationContext *context = NULL;
g_return_val_if_fail (GEGL_IS_NODE (self), NULL);
g_return_val_if_fail (context_id != NULL, NULL);
......@@ -1604,7 +1607,7 @@ void
gegl_node_remove_context (GeglNode *self,
gpointer context_id)
{
GeglNodeContext *context;
GeglOperationContext *context;
g_return_if_fail (GEGL_IS_NODE (self));
g_return_if_fail (context_id != NULL);
......@@ -1620,11 +1623,11 @@ gegl_node_remove_context (GeglNode *self,
g_object_unref (context);
}
GeglNodeContext *
GeglOperationContext *
gegl_node_add_context (GeglNode *self,
gpointer context_id)
{
GeglNodeContext *context = NULL;
GeglOperationContext *context = NULL;
GSList *found;
g_return_val_if_fail (GEGL_IS_NODE (self), NULL);
......@@ -1642,8 +1645,8 @@ gegl_node_add_context (GeglNode *self,
return context;
}
context = g_object_new (GEGL_TYPE_NODE_CONTEXT, NULL);
context->node = self;
context = g_object_new (GEGL_TYPE_OPERATION_CONTEXT, NULL);
context->operation = self->operation;
context->context_id = context_id;
self->context = g_slist_prepend (self->context, context);
return context;
......
......@@ -20,7 +20,7 @@
#ifndef __GEGL_NODE_H__
#define __GEGL_NODE_H__
#include "gegl-node-context.h"
#include "gegl-operation-context.h"
#include <gegl/buffer/gegl-buffer.h>
#include <gegl/buffer/gegl-cache.h>
......@@ -54,7 +54,7 @@ struct _GeglNode
gboolean is_root;
gboolean enabled;
GSList *context; /*< list of GeglNodeContext's corresponding to
GSList *context; /*< list of GeglOperationContext's corresponding to
evaluation contexts */
gboolean is_graph;
......@@ -133,11 +133,11 @@ GeglNode * gegl_node_adopt_child (GeglNode *self,
GType gegl_node_get_type (void) G_GNUC_CONST;
GeglNodeContext *gegl_node_get_context (GeglNode *self,
GeglOperationContext *gegl_node_get_context (GeglNode *self,
gpointer context_id);
void gegl_node_remove_context (GeglNode *self,
gpointer context_id);
GeglNodeContext *gegl_node_add_context (GeglNode *self,
GeglOperationContext *gegl_node_add_context (GeglNode *self,
gpointer context_id);
void gegl_node_add_pad (GeglNode *self,
......
......@@ -14,7 +14,7 @@
* License along with GEGL; if not, see <http://www.gnu.org/licenses/>.
*
* Copyright 2003 Calvin Williamson
* 2006 Øyvind Kolås
* 2006-2008 Øyvind Kolås
*/
#include "config.h"
......@@ -27,25 +27,25 @@
#include "gegl-types.h"
#include "gegl-node-context.h"
#include "gegl-operation-context.h"
#include "gegl-node.h"
#include "gegl-pad.h"
#include "gegl-config.h"
#include "operation/gegl-operation.h"
static void gegl_node_context_class_init (GeglNodeContextClass *klass);
static void gegl_node_context_init (GeglNodeContext *self);
static void gegl_operation_context_class_init (GeglOperationContextClass *klass);
static void gegl_operation_context_init (GeglOperationContext *self);
static void finalize (GObject *gobject);
static GValue * gegl_node_context_get_value (GeglNodeContext *self,
static GValue * gegl_operation_context_get_value (GeglOperationContext *self,
const gchar *property_name);
static GValue * gegl_node_context_add_value (GeglNodeContext *self,
static GValue * gegl_operation_context_add_value (GeglOperationContext *self,
const gchar *property_name);
G_DEFINE_TYPE (GeglNodeContext, gegl_node_context, G_TYPE_OBJECT);
G_DEFINE_TYPE (GeglOperationContext, gegl_operation_context, G_TYPE_OBJECT);
static void
gegl_node_context_class_init (GeglNodeContextClass *klass)
gegl_operation_context_class_init (GeglOperationContextClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
......@@ -53,95 +53,95 @@ gegl_node_context_class_init (GeglNodeContextClass *klass)
}
static void
gegl_node_context_init (GeglNodeContext *self)
gegl_operation_context_init (GeglOperationContext *self)
{
self->refs = 0;
self->cached = FALSE;
}
void
gegl_node_context_set_need_rect (GeglNodeContext *node,
gegl_operation_context_set_need_rect (GeglOperationContext *self,
gint x,
gint y,
gint width,
gint height)
{
g_assert (node);
node->need_rect.x = x;
node->need_rect.y = y;
node->need_rect.width = width;
node->need_rect.height = height;
g_assert (self);
self->need_rect.x = x;
self->need_rect.y = y;
self->need_rect.width = width;
self->need_rect.height = height;
}
GeglRectangle *
gegl_node_context_get_result_rect (GeglNodeContext *node)
gegl_operation_context_get_result_rect (GeglOperationContext *self)
{
return &node->result_rect;
return &self->result_rect;
}
void
gegl_node_context_set_result_rect (GeglNodeContext *node,
gegl_operation_context_set_result_rect (GeglOperationContext *self,
gint x,
gint y,
gint width,
gint height)
{
g_assert (node);
node->result_rect.x = x;
node->result_rect.y = y;
node->result_rect.width = width;
node->result_rect.height = height;
g_assert (self);
self->result_rect.x = x;
self->result_rect.y = y;
self->result_rect.width = width;
self->result_rect.height = height;
}
GeglRectangle *
gegl_node_context_get_need_rect (GeglNodeContext *node)
gegl_operation_context_get_need_rect (GeglOperationContext *self)
{
return &node->need_rect;
return &self->need_rect;
}
void
gegl_node_context_set_property (GeglNodeContext *context,
gegl_operation_context_set_property (GeglOperationContext *context,
const gchar *property_name,
const GValue *value)
{
GParamSpec *pspec;
GValue *storage;
pspec = gegl_node_find_property (context->node, property_name);
pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (G_OBJECT (context->operation)), property_name);
if (!pspec)
{
g_warning ("%s: node %s has no pad|property named '%s'",
G_STRFUNC,
gegl_node_get_debug_name (context->node),
GEGL_OPERATION_GET_CLASS (context->operation)->name,
property_name);
}
storage = gegl_node_context_add_value (context, property_name);
storage = gegl_operation_context_add_value (context, property_name);
/* storage needs to have the correct type */
g_value_init (storage, G_PARAM_SPEC_VALUE_TYPE (pspec));
g_value_copy (value, storage);
}
void
gegl_node_context_get_property (GeglNodeContext *context,
gegl_operation_context_get_property (GeglOperationContext *context,
const gchar *property_name,
GValue *value)
{
GParamSpec *pspec;
GValue *storage;
pspec = gegl_node_find_property (context->node, property_name);
pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (G_OBJECT (context->operation)), property_name);
if (!pspec)
{
g_warning ("%s: node %s has no pad|property named '%s'",
G_STRFUNC,
gegl_node_get_debug_name (context->node),
GEGL_OPERATION_GET_CLASS (context->operation)->name,
property_name);
}
storage = gegl_node_context_get_value (context, property_name);
storage = gegl_operation_context_get_value (context, property_name);
if (storage != NULL)
{
g_value_copy (storage, value);
......@@ -154,8 +154,8 @@ typedef struct Property
GValue value;
} Property;
static Property *property_new (GeglNode *node,
const gchar *property_name)
static Property *
property_new (const gchar *property_name)
{
Property *property = g_slice_new0 (Property);
......@@ -163,7 +163,8 @@ static Property *property_new (GeglNode *node,
return property;
}
static void property_destroy (Property *property)
static void
property_destroy (Property *property)
{
g_free (property->name);
g_value_unset (&property->value); /* does an unref */
......@@ -180,7 +181,7 @@ lookup_property (gconstpointer a,
}
static GValue *
gegl_node_context_get_value (GeglNodeContext *self,
gegl_operation_context_get_value (GeglOperationContext *self,
const gchar *property_name)
{
Property *property = NULL;
......@@ -199,7 +200,7 @@ gegl_node_context_get_value (GeglNodeContext *self,
}
void
gegl_node_context_remove_property (GeglNodeContext *self,
gegl_operation_context_remove_property (GeglOperationContext *self,
const gchar *property_name)
{
Property *property = NULL;
......@@ -211,8 +212,8 @@ gegl_node_context_remove_property (GeglNodeContext *self,
if (!property)
{
g_warning ("didn't find context %p for %s", property_name,
gegl_node_get_debug_name (self->node));
g_warning ("didn't find property %s for %s", property_name,
GEGL_OPERATION_GET_CLASS (self->operation)->name);
return;
}
self->property = g_slist_remove (self->property, property);
......@@ -220,7 +221,7 @@ gegl_node_context_remove_property (GeglNodeContext *self,
}
static GValue *
gegl_node_context_add_value (GeglNodeContext *self,
gegl_operation_context_add_value (GeglOperationContext *self,
const gchar *property_name)
{
Property *property = NULL;
......@@ -236,7 +237,7 @@ gegl_node_context_add_value (GeglNodeContext *self,
return &property->value;
}
property = property_new (self->node, property_name);
property = property_new (property_name);
self->property = g_slist_prepend (self->property, property);
......@@ -246,7 +247,7 @@ gegl_node_context_add_value (GeglNodeContext *self,
static void
finalize (GObject *gobject)
{
GeglNodeContext *self = GEGL_NODE_CONTEXT (gobject);
GeglOperationContext *self = GEGL_OPERATION_CONTEXT (gobject);
while (self->property)
{
......@@ -255,15 +256,14 @@ finalize (GObject *gobject)
property_destroy (property);
}
G_OBJECT_CLASS (gegl_node_context_parent_class)->finalize (gobject);
G_OBJECT_CLASS (gegl_operation_context_parent_class)->finalize (gobject);
}
void
gegl_node_context_set_object (GeglNodeContext *context,
gegl_operation_context_set_object (GeglOperationContext *context,
const gchar *padname,
GObject *data)
{
GeglNode *node;
GeglOperation *operation;
GParamSpec *pspec;
GValue value = {0,};
......@@ -272,35 +272,32 @@ gegl_node_context_set_object (GeglNodeContext *context,
* output object/value set?
*/
node = context->node;
operation = node->operation;
pspec = gegl_node_find_property (node, padname);
operation = context->operation;
pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (G_OBJECT (context->operation)), padname);
if (pspec)
{
g_value_init (&value, G_PARAM_SPEC_VALUE_TYPE (pspec));
g_value_set_object (&value, data);
gegl_node_context_set_property (context, padname, &value);
gegl_operation_context_set_property (context, padname, &value);
}
g_value_unset (&value);
g_object_unref (data); /* are we stealing the initial reference? */
}
GObject *
gegl_node_context_get_object (GeglNodeContext *context,
gegl_operation_context_get_object (GeglOperationContext *context,
const gchar *padname)
{
GeglNode *node;
GeglOperation *operation;
GObject *ret;
GParamSpec *pspec;
GValue value = { 0, };
node = context->node;
operation = node->operation;
operation = context->operation;
pspec = gegl_node_find_property (node, padname);
pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (G_OBJECT (context->operation)), padname);
g_value_init (&value, G_PARAM_SPEC_VALUE_TYPE (pspec));
gegl_node_context_get_property (context, padname, &value);
gegl_operation_context_get_property (context, padname, &value);
/* FIXME: handle other things than gobjects as well? */
ret = g_value_get_object (&value);
......@@ -315,23 +312,39 @@ gegl_node_context_get_object (GeglNodeContext *context,
}
GeglBuffer *
gegl_node_context_get_target (GeglNodeContext *context,
gegl_operation_context_get_source (GeglOperationContext *context,
const gchar *padname)
{
GeglOperation *operation;
GeglBuffer *real_input;
GeglBuffer *input;
GeglRectangle input_request;
operation = context->operation;
input_request = gegl_operation_get_required_for_output (operation, padname, &context->need_rect);
real_input = GEGL_BUFFER (gegl_operation_context_get_object (context, padname));
if (!real_input)
return NULL;
input = gegl_buffer_create_sub_buffer (real_input, &input_request);
return input;
}
GeglBuffer *
gegl_operation_context_get_target (GeglOperationContext *context,
const gchar *padname)
{
GeglBuffer *output;
GeglPad *pad;
const GeglRectangle *result;
const Babl *format;
GeglNode *node;
GeglOperation *operation;
g_return_val_if_fail (GEGL_IS_NODE_CONTEXT (context), NULL);
node = context->node;
operation = node->operation;
g_return_val_if_fail (GEGL_IS_OPERATION_CONTEXT (context), NULL);
pad = gegl_node_get_pad (node, padname);
format = gegl_pad_get_format (pad);
operation = context->operation;
node = operation->node; /* <ick */
format = gegl_operation_get_format (operation, padname);
if (format == NULL)
{
......@@ -356,29 +369,9 @@ gegl_node_context_get_target (GeglNodeContext *context,
output = gegl_buffer_new (result, format);
}
gegl_node_context_set_object (context, padname, G_OBJECT (output));
gegl_operation_context_set_object (context, padname, G_OBJECT (output));
return output;
}
GeglBuffer *
gegl_node_context_get_source (GeglNodeContext *context,
const gchar *padname)
{
GeglNode *node;
GeglOperation *operation;
GeglBuffer *real_input;
GeglBuffer *input;
GeglRectangle input_request;
node = context->node;
operation = node->operation;
input_request = gegl_operation_get_required_for_output (
operation, padname, &context->need_rect);
real_input = GEGL_BUFFER (gegl_node_context_get_object (context, padname));
if (!real_input)
return NULL;
input = gegl_buffer_create_sub_buffer (real_input, &input_request);
return input;
}
......@@ -14,37 +14,37 @@
* License along with GEGL; if not, see <http://www.gnu.org/licenses/>.
*
* Copyright 2003 Calvin Williamson
* 2006 Øyvind Kolås
* 2006-2008 Øyvind Kolås
*/
#ifndef __GEGL_NODE_CONTEXT_H__
#define __GEGL_NODE_CONTEXT_H__
#ifndef __GEGL_OPERATION_CONTEXT_H__
#define __GEGL_OPERATION_CONTEXT_H__
#include <gegl/buffer/gegl-buffer.h>
G_BEGIN_DECLS
#define GEGL_TYPE_NODE_CONTEXT (gegl_node_context_get_type ())
#define GEGL_NODE_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEGL_TYPE_NODE_CONTEXT, GeglNodeContext))
#define GEGL_NODE_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GEGL_TYPE_NODE_CONTEXT, GeglNodeContextClass))
#define GEGL_IS_NODE_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEGL_TYPE_NODE_CONTEXT))
#define GEGL_IS_NODE_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GEGL_TYPE_NODE_CONTEXT))
#define GEGL_NODE_CONTEXT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GEGL_TYPE_NODE_CONTEXT, GeglNodeContextClass))
#define GEGL_TYPE_OPERATION_CONTEXT (gegl_operation_context_get_type ())
#define GEGL_OPERATION_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEGL_TYPE_OPERATION_CONTEXT, GeglOperationContext))
#define GEGL_OPERATION_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GEGL_TYPE_OPERATION_CONTEXT, GeglOperationContextClass))
#define GEGL_IS_OPERATION_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEGL_TYPE_OPERATION_CONTEXT))
#define GEGL_IS_OPERATION_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GEGL_TYPE_OPERATION_CONTEXT))
#define GEGL_OPERATION_CONTEXT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GEGL_TYPE_OPERATION_CONTEXT, GeglOperationContextClass))
typedef struct _GeglNodeContextClass GeglNodeContextClass;
typedef struct _GeglOperationContextClass GeglOperationContextClass;
struct _GeglNodeContext
struct _GeglOperationContext
{
GObject parent_instance;
GeglNode *node;
GeglOperation *operation;
gpointer context_id;
GeglRectangle need_rect; /* the rectangle needed from this node */
GeglRectangle result_rect; /* the result computation rectangle for this node,
GeglRectangle need_rect; /* the rectangle needed from the operation */
GeglRectangle result_rect; /* the result computation rectangle for the operation ,
(will differ if the needed rect extends beyond
the defined rectangle, some operations might
event force/suggest expansion of the result
rect.. (contrast stretch?))
force/suggest expansion of the result
rect, like contrast stretching.
*/
gboolean cached; /* true if the cache can be used directly, and
recomputation of inputs is unneccesary) */
......@@ -53,54 +53,48 @@ struct _GeglNodeContext
before evaluation begins, each time data is
fetched from the op the reference count is
dropped, when it drops to zero, the op is
asked to clean it's pads
asked to clean it's pads, FIXME: should be
incorporated into the refcount of
GeglOperationContext?
*/
GSList *property; /* used internally for data being exchanged */
};
struct _GeglNodeContextClass
struct _GeglOperationContextClass
{
GObjectClass parent_class;
};
GType gegl_node_context_get_type (void) G_GNUC_CONST;
GType gegl_operation_context_get_type (void) G_GNUC_CONST;
GeglBuffer *gegl_node_context_get_target (GeglNodeContext *self,
GeglBuffer *gegl_operation_context_get_target (GeglOperationContext *self,
const gchar *padname);
GeglBuffer *gegl_node_context_get_source (GeglNodeContext *self,
GeglBuffer *gegl_operation_context_get_source (GeglOperationContext *self,
const gchar *padname);
GObject *gegl_node_context_get_object (GeglNodeContext *context,
GObject *gegl_operation_context_get_object (GeglOperationContext *context,
const gchar *padname);
void gegl_node_context_set_object (GeglNodeContext *context,
void gegl_operation_context_set_object (GeglOperationContext *context,
const gchar *padname,
GObject *data);
void gegl_node_context_set_property (GeglNodeContext *node,
void gegl_operation_context_set_property (GeglOperationContext *self,
const gchar *name,
const GValue *value);
void gegl_node_context_get_property (GeglNodeContext *node,
void gegl_operation_context_get_property (GeglOperationContext *self,
const gchar *name,
GValue *value);
/* the rest of these functions are for internal use only */
void gegl_node_context_remove_property (GeglNodeContext *self,
void gegl_operation_context_remove_property (GeglOperationContext *self,
const gchar *name);
GeglRectangle * gegl_node_context_get_need_rect (GeglNodeContext *node);
void gegl_node_context_set_need_rect (GeglNodeContext *node,
GeglRectangle * gegl_operation_context_get_need_rect (GeglOperationContext *self);
void gegl_operation_context_set_need_rect (GeglOperationContext *self,
gint x,
gint y,
gint width,
gint height);
GeglRectangle * gegl_node_context_get_result_rect (GeglNodeContext *node);
void gegl_node_context_set_result_rect (GeglNodeContext *node,
GeglRectangle * gegl_operation_context_get_result_rect (GeglOperationContext *node);
void gegl_operation_context_set_result_rect (GeglOperationContext *node,
gint x,
gint y,
gint width,
......
......@@ -48,7 +48,7 @@ static void set_property (GObject *gobject,
const GValue *value,
GParamSpec *pspec);
static gboolean gegl_operation_composer_process (GeglOperation *operation,
GeglNodeContext *context,
GeglOperationContext *context,
const gchar *output_prop,
const GeglRectangle *result);
static void attach (GeglOperation *operation);
......@@ -145,7 +145,7 @@ set_property (GObject *object,
static gboolean
gegl_operation_composer_process (GeglOperation *operation,
GeglNodeContext *context,
GeglOperationContext *context,
const gchar *output_prop,
const GeglRectangle *result)
{
......@@ -161,9 +161,9 @@ gegl_operation_composer_process (GeglOperation *operation,
return FALSE;
}
input = gegl_node_context_get_source (context, "input");
aux = gegl_node_context_get_source (context, "aux");
output = gegl_node_context_get_target (context, "output");