[gimp] app: in gimp:mask-components, don't forward empty aux when mask is fully set
- From: Ell <ell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: in gimp:mask-components, don't forward empty aux when mask is fully set
- Date: Fri, 1 Mar 2019 19:36:17 +0000 (UTC)
commit 371e35eeb84c195fde6aa397a799582854e00752
Author: Ell <ell_se yahoo com>
Date: Fri Mar 1 14:33:04 2019 -0500
app: in gimp:mask-components, don't forward empty aux when mask is fully set
... since the result needs to be fully opaque in this case, rather
than fully transparent.
app/operations/gimpoperationmaskcomponents.cc | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/app/operations/gimpoperationmaskcomponents.cc b/app/operations/gimpoperationmaskcomponents.cc
index 4634666c17..91cdb9ff7e 100644
--- a/app/operations/gimpoperationmaskcomponents.cc
+++ b/app/operations/gimpoperationmaskcomponents.cc
@@ -406,9 +406,16 @@ gimp_operation_mask_components_parent_process (GeglOperation *operation,
{
GObject *aux = gegl_operation_context_get_object (context, "aux");
- gegl_operation_context_set_object (context, "output", aux);
+ /* when there's no aux and the alpha component is masked-in, we set the
+ * result's alpha component to full opacity, rather than full
+ * transparency, so we can't just forward an empty aux in this case.
+ */
+ if (aux)
+ {
+ gegl_operation_context_set_object (context, "output", aux);
- return TRUE;
+ return TRUE;
+ }
}
return GEGL_OPERATION_CLASS (parent_class)->process (operation, context,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]