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

xchg get_required_for_output, get_invalidated_by_change (wrong

	way around i previous commit.)

	32 files changed, 232 insertions(+), 200 deletions(-)

svn path=/trunk/; revision=1988
parent ffaa95e3
2008-02-09 Øyvind Kolås <pippin@gimp.org>
xchg get_required_for_output, get_invalidated_by_change (wrong
way around i previous commit.)
32 files changed, 232 insertions(+), 200 deletions(-)
2008-02-09 Øyvind Kolås <pippin@gimp.org>
%s/adjust_result_rect/get_cached_region/
......
......@@ -53,7 +53,7 @@ typedef struct _GeglModuleDB GeglModuleDB;
* should be extended so a range of abi versions are accepted.
*/
#define GEGL_MODULE_ABI_VERSION 0x0006
#define GEGL_MODULE_ABI_VERSION 0x0007
struct _GeglModuleInfo
{
......@@ -166,16 +166,16 @@ struct _GeglOperationClass
* graph. A default implementation of this, if not provided should probably
* be to report that the entire defined region is dirtied.
*/
GeglRectangle (*get_required_for_output) (GeglOperation *operation,
GeglRectangle (*get_invalidated_by_change)(GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
/* computes the rectangle needed to be correctly computed in a buffer
* on the named input_pad, for a given result rectangle
*/
GeglRectangle (*get_invalidated_by_change) (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
GeglRectangle (*get_required_for_output) (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
/* Adjust result rect, adapts the rectangle used for computing results.
* (useful for global operations like contrast stretching, as well as
......@@ -221,14 +221,14 @@ void gegl_operation_set_source_region (GeglOperation *operat
/* retrieves the node providing data to a named input pad */
GeglNode * gegl_operation_get_source_node (GeglOperation *operation,
const gchar *pad_name);
GeglRectangle gegl_operation_get_required_for_output (GeglOperation *operation,
GeglRectangle gegl_operation_get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
GeglRectangle gegl_operation_get_bounding_box (GeglOperation *operation);
GeglRectangle gegl_operation_get_cached_region (GeglOperation *operation,
const GeglRectangle *roi);
GeglRectangle gegl_operation_get_invalidated_by_change (GeglOperation *operation,
GeglRectangle gegl_operation_get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
......
......@@ -368,7 +368,7 @@ gegl_node_context_get_source (GeglNodeContext *context,
node = context->node;
operation = node->operation;
input_request = gegl_operation_get_invalidated_by_change (
input_request = gegl_operation_get_required_for_output (
operation, padname, &context->need_rect);
real_input = GEGL_BUFFER (gegl_node_context_get_object (context, padname));
......
......@@ -534,9 +534,9 @@ source_invalidated (GeglNode *source,
if (destination->operation)
{
dirty_rect =
gegl_operation_get_required_for_output (destination->operation,
gegl_pad_get_name (destination_pad),
rect);
gegl_operation_get_invalidated_by_change (destination->operation,
gegl_pad_get_name (destination_pad),
rect);
}
else
{
......
......@@ -35,10 +35,10 @@
static void prepare (GeglOperation *operation);
static GeglRectangle get_bounding_box (GeglOperation *operation);
static GeglRectangle get_invalidated_by_change (GeglOperation *operation,
static GeglRectangle get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *region);
static GeglRectangle get_required_for_output (GeglOperation *operation,
static GeglRectangle get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
......@@ -52,8 +52,8 @@ gegl_operation_area_filter_class_init (GeglOperationAreaFilterClass *klass)
operation_class->prepare = prepare;
operation_class->get_bounding_box = get_bounding_box;
operation_class->get_required_for_output = get_required_for_output;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->get_required_for_output = get_required_for_output;
}
static void
......@@ -97,9 +97,9 @@ get_bounding_box (GeglOperation *operation)
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *region)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *region)
{
GeglOperationAreaFilter *area = GEGL_OPERATION_AREA_FILTER (operation);
GeglRectangle rect;
......@@ -121,9 +121,9 @@ get_invalidated_by_change (GeglOperation *operation,
}
static GeglRectangle
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region)
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region)
{
GeglOperationAreaFilter *area = GEGL_OPERATION_AREA_FILTER (operation);
GeglRectangle retval;
......
......@@ -56,10 +56,10 @@ static GeglNode*detect (GeglOperation *operation,
gint x,
gint y);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_invalidated_by_change (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *roi);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_required_for_output (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *roi);
G_DEFINE_TYPE (GeglOperationComposer, gegl_operation_composer,
GEGL_TYPE_OPERATION)
......@@ -78,7 +78,7 @@ gegl_operation_composer_class_init (GeglOperationComposerClass * klass)
operation_class->attach = attach;
operation_class->detect = detect;
operation_class->get_bounding_box = get_bounding_box;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->get_required_for_output = get_required_for_output;
g_object_class_install_property (object_class, PROP_OUTPUT,
g_param_spec_object ("output",
......@@ -211,9 +211,9 @@ get_bounding_box (GeglOperation *self)
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *roi)
{
GeglRectangle rect = *roi;
return rect;
......
......@@ -38,12 +38,12 @@ enum
PROP_INPUT,
};
static void get_property (GObject *gobject,
static void get_property (GObject *gobject,
guint prop_id,
GValue *value,
GParamSpec *pspec);
static void set_property (GObject *gobject,
static void set_property (GObject *gobject,
guint prop_id,
const GValue *value,
GParamSpec *pspec);
......@@ -53,13 +53,13 @@ static gboolean process (GeglOperation *operation,
const gchar *output_prop,
const GeglRectangle *result);
static void attach (GeglOperation *operation);
static void attach (GeglOperation *operation);
static GeglNode *detect (GeglOperation *operation,
gint x,
gint y);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_invalidated_by_change (GeglOperation *operation,
static GeglRectangle get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
......@@ -76,11 +76,11 @@ gegl_operation_filter_class_init (GeglOperationFilterClass * klass)
object_class->set_property = set_property;
object_class->get_property = get_property;
operation_class->process = process;
operation_class->attach = attach;
operation_class->detect = detect;
operation_class->get_bounding_box = get_bounding_box;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->process = 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",
......@@ -237,9 +237,9 @@ get_bounding_box (GeglOperation *self)
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
GeglRectangle result = *roi;
return result;
......
......@@ -43,15 +43,15 @@ static void set_property (GObject *gobject,
const GValue *value,
GParamSpec *pspec);
static gboolean process (GeglOperation *operation,
GeglNodeContext *context,
const gchar *output_prop,
const GeglRectangle *result);
static void attach (GeglOperation *operation);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
static gboolean process (GeglOperation *operation,
GeglNodeContext *context,
const gchar *output_prop,
const GeglRectangle *result);
static void attach (GeglOperation *operation);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
G_DEFINE_TYPE (GeglOperationSink, gegl_operation_sink, GEGL_TYPE_OPERATION)
......@@ -68,10 +68,10 @@ gegl_operation_sink_class_init (GeglOperationSinkClass * klass)
object_class->set_property = set_property;
object_class->get_property = get_property;
operation_class->process = process;
operation_class->attach = attach;
operation_class->get_bounding_box = get_bounding_box;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->process = process;
operation_class->attach = attach;
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_INPUT,
g_param_spec_object ("input",
......@@ -156,9 +156,9 @@ get_bounding_box (GeglOperation *self)
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
GeglRectangle rect=*roi;
return rect;
......
......@@ -51,8 +51,8 @@ static void attach (GeglOperation *operation);
G_DEFINE_TYPE (GeglOperationSource, gegl_operation_source, GEGL_TYPE_OPERATION)
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_invalidated_by_change (GeglOperation *operation,
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
static GeglRectangle get_cached_region (GeglOperation *operation,
......@@ -73,7 +73,7 @@ gegl_operation_source_class_init (GeglOperationSourceClass * klass)
operation_class->get_cached_region = get_cached_region;
operation_class->get_bounding_box = get_bounding_box;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->get_required_for_output = get_required_for_output;
g_object_class_install_property (gobject_class, PROP_OUTPUT,
g_param_spec_object ("output",
......@@ -150,9 +150,9 @@ get_bounding_box (GeglOperation *self)
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
return *roi;
}
......
......@@ -34,15 +34,15 @@
#include "buffer/gegl-buffer.h"
#include "gegl-operations.h"
static void attach (GeglOperation *self);
static void attach (GeglOperation *self);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_required_for_output (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *input_region);
static GeglRectangle get_invalidated_by_change (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *region);
static GeglRectangle get_bounding_box (GeglOperation *self);
static GeglRectangle get_invalidated_by_change (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *input_region);
static GeglRectangle get_required_for_output (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *region);
G_DEFINE_TYPE (GeglOperation, gegl_operation, G_TYPE_OBJECT)
......@@ -60,8 +60,8 @@ gegl_operation_class_init (GeglOperationClass *klass)
klass->prepare = NULL;
klass->no_cache = FALSE;
klass->get_bounding_box = get_bounding_box;
klass->get_required_for_output = get_required_for_output;
klass->get_invalidated_by_change = get_invalidated_by_change;
klass->get_required_for_output = get_required_for_output;
}
static void
......@@ -135,9 +135,9 @@ gegl_operation_get_bounding_box (GeglOperation *self)
}
GeglRectangle
gegl_operation_get_required_for_output (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *input_region)
gegl_operation_get_invalidated_by_change (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *input_region)
{
GeglOperationClass *klass;
GeglRectangle retval = { 0, };
......@@ -152,31 +152,31 @@ gegl_operation_get_required_for_output (GeglOperation *self,
input_region->height == 0)
return *input_region;
if (klass->get_required_for_output)
return klass->get_required_for_output (self, input_pad, input_region);
if (klass->get_invalidated_by_change)
return klass->get_invalidated_by_change (self, input_pad, input_region);
return *input_region;
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
GeglRectangle result = *roi;
if (operation->node->is_graph)
{
return gegl_operation_get_invalidated_by_change (operation, input_pad, roi);
return gegl_operation_get_required_for_output (operation, input_pad, roi);
}
return result;
}
GeglRectangle
gegl_operation_get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
gegl_operation_get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
GeglOperationClass *klass = GEGL_OPERATION_GET_CLASS (operation);
......@@ -184,15 +184,15 @@ gegl_operation_get_invalidated_by_change (GeglOperation *operation,
roi->height == 0)
return *roi;
g_assert (klass->get_invalidated_by_change);
g_assert (klass->get_required_for_output);
return klass->get_invalidated_by_change (operation, input_pad, roi);
return klass->get_required_for_output (operation, input_pad, roi);
}
GeglRectangle
gegl_operation_get_cached_region (GeglOperation *operation,
gegl_operation_get_cached_region (GeglOperation *operation,
const GeglRectangle *roi)
{
GeglOperationClass *klass = GEGL_OPERATION_GET_CLASS (operation);
......@@ -267,8 +267,8 @@ gegl_operation_get_source_node (GeglOperation *operation,
}
GeglRectangle *
gegl_operation_source_get_bounding_box (GeglOperation *operation,
const gchar *input_pad_name)
gegl_operation_source_get_bounding_box (GeglOperation *operation,
const gchar *input_pad_name)
{
GeglNode *node = gegl_operation_get_source_node (operation, input_pad_name);
......@@ -279,8 +279,8 @@ gegl_operation_source_get_bounding_box (GeglOperation *operation,
}
void
gegl_operation_set_source_region (GeglOperation *operation,
gpointer context_id,
gegl_operation_set_source_region (GeglOperation *operation,
gpointer context_id,
const gchar *input_pad_name,
const GeglRectangle *region)
{
......@@ -348,13 +348,13 @@ get_bounding_box (GeglOperation *self)
}
static GeglRectangle
get_required_for_output (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *input_region)
get_invalidated_by_change (GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *input_region)
{
if (self->node->is_graph)
{
return gegl_operation_get_required_for_output (
return gegl_operation_get_invalidated_by_change (
gegl_node_get_output_proxy (self->node, "output")->operation,
input_pad,
input_region);
......
......@@ -48,78 +48,76 @@ struct _GeglOperation
struct _GeglOperationClass
{
GObjectClass parent_class;
GObjectClass parent_class;
const gchar *name; /* name used to refer to this type of
operation in GEGL */
const gchar *description; /* textual description of the operation */
const gchar *categories; /* a colon seperated list of categories */
const gchar *name; /* name(string) used to create/indetify
this type of operation in GEGL*/
const gchar *description; /* textual description of the operation */
const gchar *categories; /* a colon seperated list of categories */
gboolean no_cache; /* do not create a cache for this operation */
gboolean no_cache; /* do not create a cache for this operation */
/* attach this operation with a GeglNode, override this if you are creating a
* GeglGraph, it is already defined for Filters/Sources/Composers.
*/
void (*attach) (GeglOperation *operation);
void (*attach) (GeglOperation *operation);
/* prepare() is called on each operation providing data to a node that
* is requested to provide a rendered result. When prepare is called all
* properties are known. This is the time to set desired pixel formats
* for input and output pads.
*/
void (*prepare) (GeglOperation *operation);
void (*prepare) (GeglOperation *operation);
/* Returns the bounding rectangle for the data that is defined by this op.
* (is already implemented in GeglOperationPointFilter and
* GeglOperationPointComposer, GeglOperationAreaFilter base classes.
*/
GeglRectangle (*get_bounding_box) (GeglOperation *operation);
GeglRectangle (*get_bounding_box) (GeglOperation *operation);
/* Computes the region in output (same affected rect assumed for all outputs)
* when a given region has changed on an input. Used to aggregate dirt in the
* graph. A default implementation of this, if not provided should probably
* be to report that the entire defined region is dirtied.
*/
GeglRectangle (*get_required_for_output) (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
GeglRectangle (*get_invalidated_by_change) (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
/* computes the rectangle needed to be correctly computed in a buffer
* on the named input_pad, for a given result rectangle
/* Computes the rectangle needed to be correctly computed in a buffer
* on the named input_pad, for a given region of interest.
*/
GeglRectangle (*get_invalidated_by_change) (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
GeglRectangle (*get_required_for_output) (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
/* Adjust result rect, adapts the rectangle used for computing results.
* (useful for global operations like contrast stretching, as well as
* file loaders to force caching of the full raster).
*/
GeglRectangle (*get_cached_region) (GeglOperation *operation,
const GeglRectangle *roi);
GeglRectangle (*get_cached_region) (GeglOperation *operation,
const GeglRectangle *roi);
/* Perform processing for the @output_pad, pad The result_rect provides the
* region to process. For sink operations @output_pad can be ignored but the
* result_rect is then then indicating the data available for consumption.
*/
gboolean (*process) (GeglOperation *operation,
GeglNodeContext *context,
const gchar *output_pad,
const GeglRectangle *result_rect);
/* XXX: What is GeglNode doing in this part of the API?
* Returns the node providing data for a specific location within the
* operations output. Does this recurse?, perhaps it should only point
* out which pad the data is coming from?
*/
GeglNode* (*detect) (GeglOperation *operation,
gint x,
gint y);
/* Perform processing for the @output_pad, pad The result_rect provides
* the region to process. For sink operations @output_pad can be ignored
* but the result_rect is then then indicating the data available for
* consumption.
* operations output. Does this recurse?, perhaps it should only point out
* which pad the data is coming from?
*/
gboolean (*process) (GeglOperation *operation,
GeglNodeContext *context,
const gchar *output_pad,
const GeglRectangle *result_rect);
GeglNode* (*detect) (GeglOperation *operation,
gint x,
gint y);
};
GType gegl_operation_get_type (void) G_GNUC_CONST;
GType gegl_operation_get_type (void) G_GNUC_CONST;
/* retrieves the bounding box of a connected input */
GeglRectangle * gegl_operation_source_get_bounding_box (GeglOperation *operation,
......@@ -136,14 +134,14 @@ void gegl_operation_set_source_region (GeglOperation *operat
/* retrieves the node providing data to a named input pad */
GeglNode * gegl_operation_get_source_node (GeglOperation *operation,
const gchar *pad_name);
GeglRectangle gegl_operation_get_required_for_output (GeglOperation *operation,
GeglRectangle gegl_operation_get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
GeglRectangle gegl_operation_get_bounding_box (GeglOperation *operation);
GeglRectangle gegl_operation_get_cached_region (GeglOperation *operation,
const GeglRectangle *roi);
GeglRectangle gegl_operation_get_invalidated_by_change(GeglOperation *operation,
GeglRectangle gegl_operation_get_required_for_output(GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi);
......
......@@ -135,12 +135,12 @@ gegl_operation_calc_source_regions (GeglOperation *operation,
context = gegl_node_get_context (operation->node, context_id);
request = context->need_rect;
/* for each input, get_invalidated_by_change use gegl_operation_set_source_region() */
/* for each input, get_required_for_output use gegl_operation_set_source_region() */
for (input_pads = operation->node->input_pads;input_pads;input_pads=input_pads->next)
{
const gchar *pad_name = gegl_pad_get_name (input_pads->data);
GeglRectangle rect;
rect = gegl_operation_get_invalidated_by_change (operation, pad_name, &request);
rect = gegl_operation_get_required_for_output (operation, pad_name, &request);
gegl_operation_set_source_region (operation, context_id, pad_name, &rect);
}
......
......@@ -61,10 +61,10 @@ static gboolean is_composite_node (OpAffine *affine);
static void get_source_matrix (OpAffine *affine,
Matrix3 output);
static GeglRectangle get_bounding_box (GeglOperation *op);
static GeglRectangle get_required_for_output (GeglOperation *operation,
static GeglRectangle get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region);
static GeglRectangle get_invalidated_by_change(GeglOperation *self,
static GeglRectangle get_required_for_output(GeglOperation *self,
const gchar *input_pad,
const GeglRectangle *region);
......@@ -140,9 +140,9 @@ op_affine_class_init (OpAffineClass *klass)
gobject_class->set_property = set_property;
gobject_class->get_property = get_property;
op_class->get_required_for_output = get_required_for_output;
op_class->get_bounding_box = get_bounding_box;
op_class->get_invalidated_by_change = get_invalidated_by_change;
op_class->get_bounding_box = get_bounding_box;
op_class->get_required_for_output = get_required_for_output;
op_class->detect = detect;
op_class->categories = "transform";
op_class->prepare = prepare;
......@@ -449,9 +449,9 @@ detect (GeglOperation *operation,
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *op,
const gchar *input_pad,
const GeglRectangle *region)
get_required_for_output (GeglOperation *op,
const gchar *input_pad,
const GeglRectangle *region)
{
OpAffine *affine = (OpAffine *) op;
Matrix3 inverse;
......@@ -511,9 +511,9 @@ get_invalidated_by_change (GeglOperation *op,
}
static GeglRectangle
get_required_for_output (GeglOperation *op,
const gchar *input_pad,
const GeglRectangle *input_region)
get_invalidated_by_change (GeglOperation *op,
const gchar *input_pad,
const GeglRectangle *input_region)
{
OpAffine *affine = (OpAffine *) op;
OpAffineClass *klass = OP_AFFINE_GET_CLASS (affine);
......
......@@ -91,17 +91,17 @@ get_bounding_box (GeglOperation *operation)
}
static GeglRectangle
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region)
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *input_region)
{
return *input_region;
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
return *roi;
}
......@@ -180,8 +180,8 @@ operation_class_init (GeglChantClass *klass)
operation_class->prepare = prepare;
operation_class->detect = detect;
operation_class->get_bounding_box = get_bounding_box;
operation_class->get_required_for_output = get_required_for_output;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->get_required_for_output = get_required_for_output;
operation_class->name = "remap";
operation_class->categories = "color";
......
......@@ -83,9 +83,9 @@ static void prepare (GeglOperation *operation)
}
static GeglRectangle
get_invalidated_by_change (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
get_required_for_output (GeglOperation *operation,
const gchar *input_pad,
const GeglRectangle *roi)
{
GeglRectangle result = *gegl_operation_source_get_bounding_box (operation, "input");
return result;
......@@ -144,7 +144,7 @@ operation_class_init (GeglChantClass *klass)
filter_class->process = process;
operation_class->prepare = prepare;
operation_class->get_invalidated_by_change = get_invalidated_by_change;
operation_class->get_required_for_output = get_required_for_output;
operation_class->name = "stretch-contrast";
operation_class->categories = "color:enhance";
......
......@@ -70,7 +70,7 @@ get_bounding_box (GeglOperation *operation)
}
static GeglRectangle