[gimp] Issue #1997 - Colors not properly converted to image's color space
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] Issue #1997 - Colors not properly converted to image's color space
- Date: Thu, 9 Aug 2018 18:08:58 +0000 (UTC)
commit 6938d11716a74e57100624c595a1ff936aba2a71
Author: Michael Natterer <mitch gimp org>
Date: Thu Aug 9 20:04:44 2018 +0200
Issue #1997 - Colors not properly converted to image's color space
Add a Babl space parameter to gimp_gegl_color_new() and all utility
functions using it. Pass NULL if the GimpRGB actually is sRGB, pass
the image's layer space if the color was already converted using
gimp_pickable_srgb_to_image_color() or similar.
app/core/gimpchannel.c | 8 ++++----
app/core/gimpdrawable-fill.c | 3 ++-
app/core/gimpdrawable-offset.c | 2 +-
app/core/gimpdrawable-transform.c | 4 ++--
app/core/gimpimage-merge.c | 6 ++++--
app/core/gimplayer.c | 3 ++-
app/gegl/gimp-gegl-apply-operation.c | 3 ++-
app/gegl/gimp-gegl-apply-operation.h | 1 +
app/gegl/gimp-gegl-nodes.c | 8 +++++---
app/gegl/gimp-gegl-nodes.h | 4 +++-
app/gegl/gimp-gegl-utils.c | 7 +++++--
app/gegl/gimp-gegl-utils.h | 3 ++-
app/operations/gimp-operation-config.c | 4 ++--
app/paint/gimperaser.c | 2 +-
app/paint/gimpink.c | 2 +-
app/paint/gimppaintbrush.c | 6 ++++--
app/pdb/plug-in-compat-cmds.c | 30 +++++++++++++++---------------
pdb/groups/plug_in_compat.pdb | 30 +++++++++++++++---------------
18 files changed, 71 insertions(+), 55 deletions(-)
---
diff --git a/app/core/gimpchannel.c b/app/core/gimpchannel.c
index 9211441ceb..a4af92e760 100644
--- a/app/core/gimpchannel.c
+++ b/app/core/gimpchannel.c
@@ -419,7 +419,7 @@ gimp_channel_get_node (GimpFilter *filter)
"format", color_format,
NULL);
gimp_gegl_node_set_color (channel->color_node,
- &channel->color);
+ &channel->color, NULL);
g_warn_if_fail (channel->mask_node == NULL);
@@ -608,7 +608,7 @@ gimp_channel_convert (GimpItem *item,
gimp_gegl_apply_flatten (gimp_drawable_get_buffer (drawable),
NULL, NULL,
- new_buffer, &background,
+ new_buffer, &background, NULL,
GIMP_LAYER_COLOR_SPACE_RGB_LINEAR);
gimp_drawable_set_buffer_full (drawable, FALSE, NULL,
@@ -1713,7 +1713,7 @@ gimp_channel_set_color (GimpChannel *channel,
if (gimp_filter_peek_node (GIMP_FILTER (channel)))
{
gimp_gegl_node_set_color (channel->color_node,
- &channel->color);
+ &channel->color, NULL);
}
gimp_drawable_update (GIMP_DRAWABLE (channel), 0, 0, -1, -1);
@@ -1764,7 +1764,7 @@ gimp_channel_set_opacity (GimpChannel *channel,
if (gimp_filter_peek_node (GIMP_FILTER (channel)))
{
gimp_gegl_node_set_color (channel->color_node,
- &channel->color);
+ &channel->color, NULL);
}
gimp_drawable_update (GIMP_DRAWABLE (channel), 0, 0, -1, -1);
diff --git a/app/core/gimpdrawable-fill.c b/app/core/gimpdrawable-fill.c
index 89d89c1145..5adaeeff7b 100644
--- a/app/core/gimpdrawable-fill.c
+++ b/app/core/gimpdrawable-fill.c
@@ -132,7 +132,8 @@ gimp_drawable_fill_buffer (GimpDrawable *drawable,
if (! gimp_drawable_has_alpha (drawable))
gimp_rgb_set_alpha (&image_color, 1.0);
- gegl_color = gimp_gegl_color_new (&image_color);
+ gegl_color = gimp_gegl_color_new (&image_color,
+ gimp_drawable_get_space (drawable));
gegl_buffer_set_color (buffer, NULL, gegl_color);
g_object_unref (gegl_color);
}
diff --git a/app/core/gimpdrawable-offset.c b/app/core/gimpdrawable-offset.c
index 9475e8a685..9d4c98a45b 100644
--- a/app/core/gimpdrawable-offset.c
+++ b/app/core/gimpdrawable-offset.c
@@ -102,7 +102,7 @@ gimp_drawable_offset (GimpDrawable *drawable,
gimp_pickable_srgb_to_image_color (GIMP_PICKABLE (drawable),
&bg, &bg);
- color = gimp_gegl_color_new (&bg);
+ color = gimp_gegl_color_new (&bg, gimp_drawable_get_space (drawable));
gegl_buffer_set_color (new_buffer, NULL, color);
g_object_unref (color);
}
diff --git a/app/core/gimpdrawable-transform.c b/app/core/gimpdrawable-transform.c
index 68a900b10d..350b1b8f4d 100644
--- a/app/core/gimpdrawable-transform.c
+++ b/app/core/gimpdrawable-transform.c
@@ -235,7 +235,7 @@ gimp_drawable_transform_buffer_flip (GimpDrawable *drawable,
&bg, &bg);
}
- color = gimp_gegl_color_new (&bg);
+ color = gimp_gegl_color_new (&bg, gimp_drawable_get_space (drawable));
gegl_buffer_set_color (new_buffer, NULL, color);
g_object_unref (color);
@@ -500,7 +500,7 @@ gimp_drawable_transform_buffer_rotate (GimpDrawable *drawable,
&bg, &bg);
}
- color = gimp_gegl_color_new (&bg);
+ color = gimp_gegl_color_new (&bg, gimp_drawable_get_space (drawable));
gegl_buffer_set_color (new_buffer, NULL, color);
g_object_unref (color);
diff --git a/app/core/gimpimage-merge.c b/app/core/gimpimage-merge.c
index 6b782364c2..8f98d862a4 100644
--- a/app/core/gimpimage-merge.c
+++ b/app/core/gimpimage-merge.c
@@ -589,8 +589,10 @@ gimp_image_merge_layers (GimpImage *image,
gimp_pickable_srgb_to_image_color (GIMP_PICKABLE (layer),
&bg, &bg);
- flatten_node = gimp_gegl_create_flatten_node (
- &bg, gimp_layer_get_real_composite_space (bottom_layer));
+ flatten_node = gimp_gegl_create_flatten_node
+ (&bg,
+ gimp_drawable_get_space (GIMP_DRAWABLE (layer)),
+ gimp_layer_get_real_composite_space (bottom_layer));
position = 0;
}
diff --git a/app/core/gimplayer.c b/app/core/gimplayer.c
index 272fc17e33..735bede7ee 100644
--- a/app/core/gimplayer.c
+++ b/app/core/gimplayer.c
@@ -2110,7 +2110,7 @@ gimp_layer_create_mask (GimpLayer *layer,
gimp_rgba_set (&background, 0.0, 0.0, 0.0, 0.0);
gimp_gegl_apply_flatten (src_buffer, NULL, NULL,
- dest_buffer, &background,
+ dest_buffer, &background, NULL,
GIMP_LAYER_COLOR_SPACE_RGB_LINEAR);
}
else
@@ -2449,6 +2449,7 @@ gimp_layer_remove_alpha (GimpLayer *layer,
gimp_gegl_apply_flatten (gimp_drawable_get_buffer (GIMP_DRAWABLE (layer)),
NULL, NULL,
new_buffer, &background,
+ gimp_drawable_get_space (GIMP_DRAWABLE (layer)),
gimp_layer_get_real_composite_space (layer));
gimp_drawable_set_buffer (GIMP_DRAWABLE (layer),
diff --git a/app/gegl/gimp-gegl-apply-operation.c b/app/gegl/gimp-gegl-apply-operation.c
index eb92daf8dd..46e4a67996 100644
--- a/app/gegl/gimp-gegl-apply-operation.c
+++ b/app/gegl/gimp-gegl-apply-operation.c
@@ -349,6 +349,7 @@ gimp_gegl_apply_flatten (GeglBuffer *src_buffer,
const gchar *undo_desc,
GeglBuffer *dest_buffer,
const GimpRGB *background,
+ const Babl *space,
GimpLayerColorSpace composite_space)
{
GeglNode *node;
@@ -358,7 +359,7 @@ gimp_gegl_apply_flatten (GeglBuffer *src_buffer,
g_return_if_fail (GEGL_IS_BUFFER (dest_buffer));
g_return_if_fail (background != NULL);
- node = gimp_gegl_create_flatten_node (background, composite_space);
+ node = gimp_gegl_create_flatten_node (background, space, composite_space);
gimp_gegl_apply_operation (src_buffer, progress, undo_desc,
node, dest_buffer, NULL, FALSE);
diff --git a/app/gegl/gimp-gegl-apply-operation.h b/app/gegl/gimp-gegl-apply-operation.h
index 61df148e61..ad863db2be 100644
--- a/app/gegl/gimp-gegl-apply-operation.h
+++ b/app/gegl/gimp-gegl-apply-operation.h
@@ -61,6 +61,7 @@ void gimp_gegl_apply_flatten (GeglBuffer *src_buffer,
const gchar *undo_desc,
GeglBuffer *dest_buffer,
const GimpRGB *background,
+ const Babl *space,
GimpLayerColorSpace composite_space);
void gimp_gegl_apply_feather (GeglBuffer *src_buffer,
diff --git a/app/gegl/gimp-gegl-nodes.c b/app/gegl/gimp-gegl-nodes.c
index 3236f3d5e9..6bca2dd0d8 100644
--- a/app/gegl/gimp-gegl-nodes.c
+++ b/app/gegl/gimp-gegl-nodes.c
@@ -32,6 +32,7 @@
GeglNode *
gimp_gegl_create_flatten_node (const GimpRGB *background,
+ const Babl *space,
GimpLayerColorSpace composite_space)
{
GeglNode *node;
@@ -51,7 +52,7 @@ gimp_gegl_create_flatten_node (const GimpRGB *background,
input = gegl_node_get_input_proxy (node, "input");
output = gegl_node_get_output_proxy (node, "output");
- c = gimp_gegl_color_new (background);
+ c = gimp_gegl_color_new (background, space);
color = gegl_node_new_child (node,
"operation", "gegl:color",
"value", c,
@@ -217,14 +218,15 @@ gimp_gegl_node_set_matrix (GeglNode *node,
void
gimp_gegl_node_set_color (GeglNode *node,
- const GimpRGB *color)
+ const GimpRGB *color,
+ const Babl *space)
{
GeglColor *gegl_color;
g_return_if_fail (GEGL_IS_NODE (node));
g_return_if_fail (color != NULL);
- gegl_color = gimp_gegl_color_new (color);
+ gegl_color = gimp_gegl_color_new (color, space);
gegl_node_set (node,
"value", gegl_color,
diff --git a/app/gegl/gimp-gegl-nodes.h b/app/gegl/gimp-gegl-nodes.h
index 90f13fc2b2..55c033e32f 100644
--- a/app/gegl/gimp-gegl-nodes.h
+++ b/app/gegl/gimp-gegl-nodes.h
@@ -23,6 +23,7 @@
GeglNode * gimp_gegl_create_flatten_node (const GimpRGB *background,
+ const Babl *space,
GimpLayerColorSpace composite_space);
GeglNode * gimp_gegl_create_apply_opacity_node (GeglBuffer *mask,
gint mask_offset_x,
@@ -44,7 +45,8 @@ void gimp_gegl_mode_node_set_opacity (GeglNode *node,
void gimp_gegl_node_set_matrix (GeglNode *node,
const GimpMatrix3 *matrix);
void gimp_gegl_node_set_color (GeglNode *node,
- const GimpRGB *color);
+ const GimpRGB *color,
+ const Babl *space);
#endif /* __GIMP_GEGL_NODES_H__ */
diff --git a/app/gegl/gimp-gegl-utils.c b/app/gegl/gimp-gegl-utils.c
index 96d3936776..30e9afa680 100644
--- a/app/gegl/gimp-gegl-utils.c
+++ b/app/gegl/gimp-gegl-utils.c
@@ -61,14 +61,17 @@ gimp_gegl_get_op_enum_type (const gchar *operation,
}
GeglColor *
-gimp_gegl_color_new (const GimpRGB *rgb)
+gimp_gegl_color_new (const GimpRGB *rgb,
+ const Babl *space)
{
GeglColor *color;
g_return_val_if_fail (rgb != NULL, NULL);
color = gegl_color_new (NULL);
- gegl_color_set_pixel (color, babl_format ("R'G'B'A double"), rgb);
+ gegl_color_set_pixel (color,
+ babl_format_with_space ("R'G'B'A double", space),
+ rgb);
return color;
}
diff --git a/app/gegl/gimp-gegl-utils.h b/app/gegl/gimp-gegl-utils.h
index cc25338aa4..7903532f38 100644
--- a/app/gegl/gimp-gegl-utils.h
+++ b/app/gegl/gimp-gegl-utils.h
@@ -25,7 +25,8 @@
GType gimp_gegl_get_op_enum_type (const gchar *operation,
const gchar *property);
-GeglColor * gimp_gegl_color_new (const GimpRGB *rgb);
+GeglColor * gimp_gegl_color_new (const GimpRGB *rgb,
+ const Babl *space);
void gimp_gegl_progress_connect (GeglNode *node,
GimpProgress *progress,
diff --git a/app/operations/gimp-operation-config.c b/app/operations/gimp-operation-config.c
index 88ff32e90e..29e9d812f5 100644
--- a/app/operations/gimp-operation-config.c
+++ b/app/operations/gimp-operation-config.c
@@ -540,7 +540,7 @@ gimp_operation_config_sync_node (GObject *config,
gimp_value_get_rgb (&value, &gimp_color);
g_value_unset (&value);
- gegl_color = gimp_gegl_color_new (&gimp_color);
+ gegl_color = gimp_gegl_color_new (&gimp_color, NULL);
g_value_init (&value, gegl_pspec->value_type);
g_value_take_object (&value, gegl_color);
@@ -699,7 +699,7 @@ gimp_operation_config_config_notify (GObject *config,
gimp_value_get_rgb (&value, &gimp_color);
g_value_unset (&value);
- gegl_color = gimp_gegl_color_new (&gimp_color);
+ gegl_color = gimp_gegl_color_new (&gimp_color, NULL);
g_value_init (&value, gegl_pspec->value_type);
g_value_take_object (&value, gegl_color);
diff --git a/app/paint/gimperaser.c b/app/paint/gimperaser.c
index 1ebb36ec4c..1074591ddc 100644
--- a/app/paint/gimperaser.c
+++ b/app/paint/gimperaser.c
@@ -157,7 +157,7 @@ gimp_eraser_motion (GimpPaintCore *paint_core,
gimp_context_get_background (context, &background);
gimp_pickable_srgb_to_image_color (GIMP_PICKABLE (drawable),
&background, &background);
- color = gimp_gegl_color_new (&background);
+ color = gimp_gegl_color_new (&background, gimp_drawable_get_space (drawable));
if (options->anti_erase)
paint_mode = GIMP_LAYER_MODE_ANTI_ERASE;
diff --git a/app/paint/gimpink.c b/app/paint/gimpink.c
index 195dacb13f..ce4e018b21 100644
--- a/app/paint/gimpink.c
+++ b/app/paint/gimpink.c
@@ -392,7 +392,7 @@ gimp_ink_motion (GimpPaintCore *paint_core,
gimp_context_get_foreground (context, &foreground);
gimp_pickable_srgb_to_image_color (GIMP_PICKABLE (drawable),
&foreground, &foreground);
- color = gimp_gegl_color_new (&foreground);
+ color = gimp_gegl_color_new (&foreground, gimp_drawable_get_space (drawable));
for (i = 0; i < n_strokes; i++)
{
diff --git a/app/paint/gimppaintbrush.c b/app/paint/gimppaintbrush.c
index 0766058380..367d1c0f94 100644
--- a/app/paint/gimppaintbrush.c
+++ b/app/paint/gimppaintbrush.c
@@ -217,7 +217,8 @@ _gimp_paintbrush_motion (GimpPaintCore *paint_core,
opacity *= gradient_color.a;
gimp_rgb_set_alpha (&gradient_color, GIMP_OPACITY_OPAQUE);
- color = gimp_gegl_color_new (&gradient_color);
+ color = gimp_gegl_color_new (&gradient_color,
+ NULL /* EEK SPACE? */);
gegl_buffer_set_color (paint_buffer, NULL, color);
g_object_unref (color);
@@ -248,7 +249,8 @@ _gimp_paintbrush_motion (GimpPaintCore *paint_core,
gimp_context_get_foreground (context, &foreground);
gimp_pickable_srgb_to_image_color (GIMP_PICKABLE (drawable),
&foreground, &foreground);
- color = gimp_gegl_color_new (&foreground);
+ color = gimp_gegl_color_new (&foreground,
+ gimp_drawable_get_space (drawable));
gegl_buffer_set_color (paint_buffer, NULL, color);
g_object_unref (color);
diff --git a/app/pdb/plug-in-compat-cmds.c b/app/pdb/plug-in-compat-cmds.c
index fc0d172181..44783264cc 100644
--- a/app/pdb/plug-in-compat-cmds.c
+++ b/app/pdb/plug-in-compat-cmds.c
@@ -535,7 +535,7 @@ plug_in_applylens_invoker (GimpProcedure *procedure,
else
gimp_rgba_set (&color, 0.0, 0.0, 0.0, 0.0);
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:apply-lens",
@@ -972,7 +972,7 @@ plug_in_colortoalpha_invoker (GimpProcedure *procedure,
{
/* XXX: fixme disable for gray, and add alpha when needed */
- GeglColor *gegl_color = gimp_gegl_color_new (&color);
+ GeglColor *gegl_color = gimp_gegl_color_new (&color, NULL);
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:color-to-alpha",
@@ -1158,7 +1158,7 @@ plug_in_cubism_invoker (GimpProcedure *procedure,
gimp_rgba_set (&color, 0.0, 0.0, 0.0, 0.0);
}
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:cubism",
@@ -1553,8 +1553,8 @@ plug_in_exchange_invoker (GimpProcedure *procedure,
gimp_rgb_set_uchar (&from, from_red, from_green, from_blue);
gimp_rgb_set_uchar (&to, to_red, to_green, to_blue);
- gegl_from = gimp_gegl_color_new (&from);
- gegl_to = gimp_gegl_color_new (&to);
+ gegl_from = gimp_gegl_color_new (&from, NULL);
+ gegl_to = gimp_gegl_color_new (&to, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:color-exchange",
@@ -1992,7 +1992,7 @@ plug_in_lens_distortion_invoker (GimpProcedure *procedure,
gimp_rgb_set_alpha (&color, 1.0);
}
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:lens-distortion",
@@ -2097,10 +2097,10 @@ plug_in_maze_invoker (GimpProcedure *procedure,
GimpRGB color;
gimp_context_get_foreground (context, &color);
- fg_color = gimp_gegl_color_new (&color);
+ fg_color = gimp_gegl_color_new (&color, NULL);
gimp_context_get_background (context, &color);
- bg_color = gimp_gegl_color_new (&color);
+ bg_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:maze",
@@ -2352,10 +2352,10 @@ plug_in_mosaic_invoker (GimpProcedure *procedure,
GimpRGB fgcolor, bgcolor;
gimp_context_get_background (context, &bgcolor);
- bg_color = gimp_gegl_color_new (&bgcolor);
+ bg_color = gimp_gegl_color_new (&bgcolor, NULL);
gimp_context_get_foreground (context, &fgcolor);
- fg_color = gimp_gegl_color_new (&fgcolor);
+ fg_color = gimp_gegl_color_new (&fgcolor, NULL);
}
else
{
@@ -2429,7 +2429,7 @@ plug_in_nova_invoker (GimpProcedure *procedure,
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node;
- GeglColor *gegl_color = gimp_gegl_color_new (&color);
+ GeglColor *gegl_color = gimp_gegl_color_new (&color, NULL);
gdouble center_x = (gdouble) xcenter / (gdouble) gimp_item_get_width (GIMP_ITEM (drawable));
gdouble center_y = (gdouble) ycenter / (gdouble) gimp_item_get_height (GIMP_ITEM (drawable));
@@ -2520,7 +2520,7 @@ plug_in_papertile_invoker (GimpProcedure *procedure,
break;
}
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:tile-paper",
@@ -3404,8 +3404,8 @@ plug_in_sinus_invoker (GimpProcedure *procedure,
gimp_rgb_set_alpha (&col1, alpha1);
gimp_rgb_set_alpha (&col2, alpha2);
- gegl_color1 = gimp_gegl_color_new (&col1);
- gegl_color2 = gimp_gegl_color_new (&col2);
+ gegl_color1 = gimp_gegl_color_new (&col1, NULL);
+ gegl_color2 = gimp_gegl_color_new (&col2, NULL);
gimp_item_mask_intersect (GIMP_ITEM (drawable), &x, &y, &width, &height);
@@ -3827,7 +3827,7 @@ plug_in_vpropagate_invoker (GimpProcedure *procedure,
else
gimp_context_get_background (context, &color);
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
break;
case 6:
diff --git a/pdb/groups/plug_in_compat.pdb b/pdb/groups/plug_in_compat.pdb
index ba843deae5..cd1884ade2 100644
--- a/pdb/groups/plug_in_compat.pdb
+++ b/pdb/groups/plug_in_compat.pdb
@@ -224,7 +224,7 @@ HELP
else
gimp_rgba_set (&color, 0.0, 0.0, 0.0, 0.0);
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:apply-lens",
@@ -724,7 +724,7 @@ HELP
{
/* XXX: fixme disable for gray, and add alpha when needed */
- GeglColor *gegl_color = gimp_gegl_color_new (&color);
+ GeglColor *gegl_color = gimp_gegl_color_new (&color, NULL);
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:color-to-alpha",
@@ -922,7 +922,7 @@ HELP
gimp_rgba_set (&color, 0.0, 0.0, 0.0, 0.0);
}
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:cubism",
@@ -1370,8 +1370,8 @@ HELP
gimp_rgb_set_uchar (&from, from_red, from_green, from_blue);
gimp_rgb_set_uchar (&to, to_red, to_green, to_blue);
- gegl_from = gimp_gegl_color_new (&from);
- gegl_to = gimp_gegl_color_new (&to);
+ gegl_from = gimp_gegl_color_new (&from, NULL);
+ gegl_to = gimp_gegl_color_new (&to, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:color-exchange",
@@ -1901,7 +1901,7 @@ HELP
gimp_rgb_set_alpha (&color, 1.0);
}
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:lens-distortion",
@@ -2023,10 +2023,10 @@ HELP
GimpRGB color;
gimp_context_get_foreground (context, &color);
- fg_color = gimp_gegl_color_new (&color);
+ fg_color = gimp_gegl_color_new (&color, NULL);
gimp_context_get_background (context, &color);
- bg_color = gimp_gegl_color_new (&color);
+ bg_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:maze",
@@ -2301,10 +2301,10 @@ HELP
GimpRGB fgcolor, bgcolor;
gimp_context_get_background (context, &bgcolor);
- bg_color = gimp_gegl_color_new (&bgcolor);
+ bg_color = gimp_gegl_color_new (&bgcolor, NULL);
gimp_context_get_foreground (context, &fgcolor);
- fg_color = gimp_gegl_color_new (&fgcolor);
+ fg_color = gimp_gegl_color_new (&fgcolor, NULL);
}
else
{
@@ -2386,7 +2386,7 @@ HELP
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node;
- GeglColor *gegl_color = gimp_gegl_color_new (&color);
+ GeglColor *gegl_color = gimp_gegl_color_new (&color, NULL);
gdouble center_x = (gdouble) xcenter / (gdouble) gimp_item_get_width (GIMP_ITEM (drawable));
gdouble center_y = (gdouble) ycenter / (gdouble) gimp_item_get_height (GIMP_ITEM (drawable));
@@ -2485,7 +2485,7 @@ HELP
break;
}
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
node = gegl_node_new_child (NULL,
"operation", "gegl:tile-paper",
@@ -3486,8 +3486,8 @@ sub plug_in_sinus {
gimp_rgb_set_alpha (&col1, alpha1);
gimp_rgb_set_alpha (&col2, alpha2);
- gegl_color1 = gimp_gegl_color_new (&col1);
- gegl_color2 = gimp_gegl_color_new (&col2);
+ gegl_color1 = gimp_gegl_color_new (&col1, NULL);
+ gegl_color2 = gimp_gegl_color_new (&col2, NULL);
gimp_item_mask_intersect (GIMP_ITEM (drawable), &x, &y, &width, &height);
@@ -3973,7 +3973,7 @@ HELP
else
gimp_context_get_background (context, &color);
- gegl_color = gimp_gegl_color_new (&color);
+ gegl_color = gimp_gegl_color_new (&color, NULL);
break;
case 6:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]