From 13b1ef007509b9ebfaa326583e04d29c2e1940f6 Mon Sep 17 00:00:00 2001 From: Filip Sykala Date: Mon, 20 Jun 2022 18:52:12 +0200 Subject: [PATCH] fix over zero cycling --- src/libslic3r/CutSurface.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libslic3r/CutSurface.cpp b/src/libslic3r/CutSurface.cpp index 412eaa42e..8126f1ac1 100644 --- a/src/libslic3r/CutSurface.cpp +++ b/src/libslic3r/CutSurface.cpp @@ -2111,7 +2111,7 @@ priv::ProjectionDistances priv::choose_best_distance( // Negative iteration inside polygon do { uint32_t nxt_index = (act_index == first_index) ? - last_index : (act_index - 1); + (last_index-1) : (act_index - 1); // When iterate negative it must be split to parts // and can't iterate in circle assert(nxt_index != index);