Skip to content

Commit

Permalink
Allow to load monotonicgapfill for solid_fill_pattern
Browse files Browse the repository at this point in the history
now that it's in the list.
#3281
  • Loading branch information
supermerill committed May 15, 2024
1 parent 2628f20 commit dac85c2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/libslic3r/PerimeterGenerator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1901,7 +1901,7 @@ ProcessSurfaceResult PerimeterGenerator::process_classic(int& contour_count, int
}
}
assert(contours.size() == contour_count);
assert(holes.size() == holes_count);
//assert(holes.size() == holes_count);
// nest loops: holes first
for (int d = 0; d < holes_count; ++d) {
PerimeterGeneratorLoops& holes_d = holes[d];
Expand Down
10 changes: 6 additions & 4 deletions src/libslic3r/PrintConfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7817,11 +7817,13 @@ void PrintConfigDef::handle_legacy(t_config_option_key &opt_key, std::string &va
|| opt_key == "solid_fill_pattern" || opt_key == "bridge_fill_pattern" || opt_key == "support_material_interface_pattern"))
value = "monotonic";
// some changes has occurs between rectilineargapfill and monotonicgapfill. Set them at the right value for each type
if (value == "rectilineargapfill" && (opt_key == "top_fill_pattern" || opt_key == "bottom_fill_pattern" || opt_key == "fill_pattern" || opt_key == "support_material_interface_pattern"))
if (value == "rectilineargapfill" && (opt_key == "top_fill_pattern" || opt_key == "bottom_fill_pattern") )
value = "monotonicgapfill";
if (value == "monotonicgapfill" && (opt_key == "solid_fill_pattern"))
value = "rectilineargapfill";

if (opt_key == "fill_pattern" || opt_key == "support_material_interface_pattern")
if (value == "rectilineargapfill")
value = "rectilinear";
else if (value == "monotonicgapfill")
value = "monotonic";

if (ignore.find(opt_key) != ignore.end()) {
opt_key = "";
Expand Down

0 comments on commit dac85c2

Please sign in to comment.