From 73f8ffe76a8e66bbcaf3e7a49a692eb7aeb6201a Mon Sep 17 00:00:00 2001 From: Yuri D'Elia Date: Fri, 19 Jul 2019 12:59:57 +0200 Subject: [PATCH] Limit upper tolerance in Gyroid Do not reduce resolution more than necessary when using larger nozzles and/or higher layer heights. --- src/libslic3r/Fill/FillGyroid.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libslic3r/Fill/FillGyroid.cpp b/src/libslic3r/Fill/FillGyroid.cpp index 1e1e35b9e..651abffd9 100644 --- a/src/libslic3r/Fill/FillGyroid.cpp +++ b/src/libslic3r/Fill/FillGyroid.cpp @@ -106,9 +106,9 @@ static Polylines make_gyroid_waves(double gridZ, double density_adjusted, double { const double scaleFactor = scale_(line_spacing) / density_adjusted; - // tolerance (in scaled units) - // TODO: should consider layer thickness - const double tolerance = line_spacing / 2 / unscale(scaleFactor); + // tolerance (in scaled units) - note: clamp the maximum tolerance + // as there's no benefit to reduce the definition with large nozzles + const double tolerance = std::min(line_spacing, 0.4) / 2 / unscale(scaleFactor); //scale factor for 5% : 8 712 388 // 1z = 10^-6 mm ?