[gimp] app: change the way the operation for layer compositing is determined
- From: Michael Natterer <mitch src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp] app: change the way the operation for layer compositing is determined
- Date: Wed, 30 Dec 2009 17:03:39 +0000 (UTC)
commit 37b6a205d3c5d3a3b5425ff776a1364417c936d6
Author: Michael Natterer <mitch gimp org>
Date: Wed Dec 30 18:01:09 2009 +0100
app: change the way the operation for layer compositing is determined
By default, get the operation from gimp_layer_mode_to_gegl_operation()
and special-case all modes except from "normal", so the special cases
actually become less as the new operations are filled with code.
app/core/gimplayer.c | 33 +++++++++++++++++++++++++++++----
1 files changed, 29 insertions(+), 4 deletions(-)
---
diff --git a/app/core/gimplayer.c b/app/core/gimplayer.c
index d0584aa..b03cdb4 100644
--- a/app/core/gimplayer.c
+++ b/app/core/gimplayer.c
@@ -1026,16 +1026,41 @@ gimp_layer_sync_mode_node (GimpLayer *layer)
switch (layer->mode)
{
- case GIMP_NORMAL_MODE:
+ case GIMP_DISSOLVE_MODE:
+ case GIMP_BEHIND_MODE:
+ case GIMP_MULTIPLY_MODE:
+ case GIMP_SCREEN_MODE:
+ case GIMP_OVERLAY_MODE:
+ case GIMP_DIFFERENCE_MODE:
+ case GIMP_ADDITION_MODE:
+ case GIMP_SUBTRACT_MODE:
+ case GIMP_DARKEN_ONLY_MODE:
+ case GIMP_LIGHTEN_ONLY_MODE:
+ case GIMP_HUE_MODE:
+ case GIMP_SATURATION_MODE:
+ case GIMP_COLOR_MODE:
+ case GIMP_VALUE_MODE:
+ case GIMP_DIVIDE_MODE:
+ case GIMP_DODGE_MODE:
+ case GIMP_BURN_MODE:
+ case GIMP_HARDLIGHT_MODE:
+ case GIMP_SOFTLIGHT_MODE:
+ case GIMP_GRAIN_EXTRACT_MODE:
+ case GIMP_GRAIN_MERGE_MODE:
+ case GIMP_COLOR_ERASE_MODE:
+ case GIMP_ERASE_MODE:
+ case GIMP_REPLACE_MODE:
+ case GIMP_ANTI_ERASE_MODE:
gegl_node_set (mode_node,
- "operation", "gegl:over",
+ "operation", "gimp:point-layer-mode",
+ "blend-mode", layer->mode,
NULL);
break;
default:
gegl_node_set (mode_node,
- "operation", "gimp:point-layer-mode",
- "blend-mode", layer->mode,
+ "operation",
+ gimp_layer_mode_to_gegl_operation (layer->mode),
NULL);
break;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]