[gimp] app: fix mask overlay position when zoom != 100%



commit 09e1c7f9b5d0c59fcbc473d03a65edf0c51600ef
Author: Ell <ell_se yahoo com>
Date:   Sun Dec 31 11:34:58 2017 -0500

    app: fix mask overlay position when zoom != 100%
    
    ... and the mask offset != (0, 0)
    
    Thanks tmanni!

 app/display/gimpdisplayshell-render.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/app/display/gimpdisplayshell-render.c b/app/display/gimpdisplayshell-render.c
index 9b03231..167d67a 100644
--- a/app/display/gimpdisplayshell-render.c
+++ b/app/display/gimpdisplayshell-render.c
@@ -300,8 +300,8 @@ gimp_display_shell_render (GimpDisplayShell *shell,
                      mask_src_y * cairo_stride + mask_src_x;
 
       gegl_buffer_get (shell->mask,
-                       GEGL_RECTANGLE (x - shell->mask_offset_x,
-                                       y - shell->mask_offset_y,
+                       GEGL_RECTANGLE (x - floor (shell->mask_offset_x * scale),
+                                       y - floor (shell->mask_offset_y * scale),
                                        w, h),
                        scale,
                        babl_format ("Y u8"),


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]