diff --git a/include/settings/EnumSettings.h b/include/settings/EnumSettings.h index 7b8c970db4..333fa1d07a 100644 --- a/include/settings/EnumSettings.h +++ b/include/settings/EnumSettings.h @@ -250,11 +250,6 @@ enum class InsetDirection */ enum class PrimeTowerMethod { - /*! - * No prime tower is generated. - */ - NONE, - /*! * Prime tower that minimizes time and used filament as much as possible. */ diff --git a/src/FffGcodeWriter.cpp b/src/FffGcodeWriter.cpp index d4c64cb685..e45912fdb9 100644 --- a/src/FffGcodeWriter.cpp +++ b/src/FffGcodeWriter.cpp @@ -1602,8 +1602,6 @@ std::vector switch (method) { - case PrimeTowerMethod::NONE: - break; case PrimeTowerMethod::NORMAL: if (extruder_is_used_on_this_layer[extruder_nr] && extruder_nr != last_extruder) diff --git a/src/FffPolygonGenerator.cpp b/src/FffPolygonGenerator.cpp index c5c33dcc01..f2fcbe8910 100644 --- a/src/FffPolygonGenerator.cpp +++ b/src/FffPolygonGenerator.cpp @@ -972,7 +972,7 @@ void FffPolygonGenerator::processOozeShield(SliceDataStorage& storage) { storage.oozeShield[layer_nr].removeSmallAreas(largest_printed_area); } - if (mesh_group_settings.get("prime_tower_mode") != PrimeTowerMethod::NONE) + if (mesh_group_settings.get("prime_tower_enable")) { coord_t max_line_width = 0; { // compute max_line_width @@ -1024,7 +1024,7 @@ void FffPolygonGenerator::processDraftShield(SliceDataStorage& storage) maximum_deviation = std::min(maximum_deviation, extruder.settings_.get("meshfix_maximum_deviation")); } storage.draft_protection_shield = Simplify(maximum_resolution, maximum_deviation, 0).polygon(storage.draft_protection_shield); - if (mesh_group_settings.get("prime_tower_mode") != PrimeTowerMethod::NONE) + if (mesh_group_settings.get("prime_tower_enable")) { coord_t max_line_width = 0; { // compute max_line_width diff --git a/src/PrimeTower.cpp b/src/PrimeTower.cpp index 5264ecb346..180a79a331 100644 --- a/src/PrimeTower.cpp +++ b/src/PrimeTower.cpp @@ -48,7 +48,7 @@ PrimeTower::PrimeTower() && ((adhesion_type != EPlatformAdhesion::SKIRT) && (adhesion_type != EPlatformAdhesion::BRIM))); } - enabled_ = method != PrimeTowerMethod::NONE && scene.current_mesh_group->settings.get("prime_tower_min_volume") > 10 + enabled_ = scene.current_mesh_group->settings.get("prime_tower_enable") && scene.current_mesh_group->settings.get("prime_tower_min_volume") > 10 && scene.current_mesh_group->settings.get("prime_tower_size") > 10; would_have_actual_tower_ = enabled_; // Assume so for now. diff --git a/src/settings/Settings.cpp b/src/settings/Settings.cpp index b94364d9e5..fb40910eef 100644 --- a/src/settings/Settings.cpp +++ b/src/settings/Settings.cpp @@ -686,14 +686,8 @@ PrimeTowerMethod Settings::get(const std::string& key) const { return PrimeTowerMethod::INTERLEAVED; } - else if (value == "normal") - { - return PrimeTowerMethod::NORMAL; - } - else // Default. - { - return PrimeTowerMethod::NONE; - } + + return PrimeTowerMethod::NORMAL; } template<>