[gimp/multi-stroke: 14/28] app: fix max strokes on x/y axis for tiling symmetry.



commit d5aa9480f2d1f36dd3ff864aebe3022a3e7dbcbb
Author: Jehan <jehan girinstud io>
Date:   Sun Mar 22 01:10:59 2015 +0100

    app: fix max strokes on x/y axis for tiling symmetry.

 app/core/gimpsymmetry-tiling.c |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/app/core/gimpsymmetry-tiling.c b/app/core/gimpsymmetry-tiling.c
index bf7c89b..8143aa5 100644
--- a/app/core/gimpsymmetry-tiling.c
+++ b/app/core/gimpsymmetry-tiling.c
@@ -314,20 +314,20 @@ gimp_tiling_update_strokes (GimpSymmetry *sym,
   for (y_count = 0, y = starty; y < height + tiling->interval_y;
        y_count++, y += tiling->interval_y)
     {
+      if (tiling->interval_y < 1.0 ||
+          (tiling->max_y && y_count >= (gint) tiling->max_y))
+        break;
       for (x_count = 0, x = startx; x < width + tiling->interval_x;
            x_count++, x += tiling->interval_x)
         {
+          if (tiling->interval_x < 1.0 ||
+              (tiling->max_x && x_count >= (gint) tiling->max_x))
+            break;
           coords = g_memdup (origin, sizeof (GimpCoords));
           coords->x = x;
           coords->y = y;
           strokes = g_list_prepend (strokes, coords);
-          if (tiling->interval_x < 1.0 ||
-              (tiling->max_x && x_count >= (gint) tiling->max_x))
-            break;
         }
-      if (tiling->interval_y < 1.0 ||
-          (tiling->max_y && y_count >= (gint) tiling->max_y))
-        break;
       if (tiling->max_x || startx + tiling->shift <= 0.0)
         startx = startx + tiling->shift;
       else


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