[gimp] app: fix alpha to selection on single layer with offset.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: fix alpha to selection on single layer with offset.
- Date: Wed, 21 Oct 2020 15:37:32 +0000 (UTC)
commit 1a90a2df3271d7d45477ed3b8a4641aa969abd0d
Author: Jehan <jehan girinstud io>
Date: Wed Oct 21 17:36:58 2020 +0200
app: fix alpha to selection on single layer with offset.
app/core/gimpchannel-combine.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/app/core/gimpchannel-combine.c b/app/core/gimpchannel-combine.c
index db8ccab7c9..db2a428abf 100644
--- a/app/core/gimpchannel-combine.c
+++ b/app/core/gimpchannel-combine.c
@@ -559,11 +559,15 @@ gimp_channel_combine_items (GimpChannel *mask,
if (gimp_drawable_has_alpha (layers->data))
{
GimpChannel *alpha;
+ gint offset_x;
+ gint offset_y;
alpha = gimp_channel_new_from_alpha (image,
layers->data, NULL, NULL);
+ gimp_item_get_offset (layers->data, &offset_x, &offset_y);
gimp_channel_combine_mask (channel, alpha,
- GIMP_CHANNEL_OP_REPLACE, 0, 0);
+ GIMP_CHANNEL_OP_REPLACE,
+ offset_x, offset_y);
g_object_unref (alpha);
}
else
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]