From 9328681428b008caa9f676b16df50d0c4de31e84 Mon Sep 17 00:00:00 2001 From: supermerill Date: Sun, 10 Oct 2021 15:28:07 +0200 Subject: [PATCH] Fix bad check for default_acceleration when diabled and exporting config. supermerill/SuperSlicer#1622 --- src/libslic3r/PrintConfig.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/libslic3r/PrintConfig.cpp b/src/libslic3r/PrintConfig.cpp index c5ae79bd8..3e5f52572 100644 --- a/src/libslic3r/PrintConfig.cpp +++ b/src/libslic3r/PrintConfig.cpp @@ -6482,6 +6482,7 @@ std::set DynamicPrintConfig::value_changed(const t_co } //FIXME localize this function. +//note: seems only called for config export & command line. Most of the validation work for the gui is done elsewhere... So this function may be a bit out-of-sync std::string FullPrintConfig::validate() { // --layer-height @@ -6558,7 +6559,7 @@ std::string FullPrintConfig::validate() // --fill-density if (fabs(this->fill_density.value - 100.) < EPSILON && (! print_config_def.get("top_fill_pattern")->has_enum_value(this->fill_pattern.serialize()) - || ! print_config_def.get("bottom_fill_pattern")->has_enum_value(this->fill_pattern.serialize()) + && ! print_config_def.get("bottom_fill_pattern")->has_enum_value(this->fill_pattern.serialize()) )) return "The selected fill pattern is not supposed to work at 100% density"; @@ -6581,11 +6582,6 @@ std::string FullPrintConfig::validate() if (em <= 0) return "Invalid value for --extrusion-multiplier"; - // --default-acceleration - if ((this->perimeter_acceleration.value != 0. || this->infill_acceleration.value != 0. || this->bridge_acceleration.value != 0. || this->first_layer_acceleration.value != 0.) && - this->default_acceleration.value == 0.) - return "Invalid zero value for --default-acceleration when using other acceleration settings"; - // --spiral-vase if (this->spiral_vase) { // Note that we might want to have more than one perimeter on the bottom