SPE-2718: Allow scarf start and end can be equal for entire loop

This commit is contained in:
Martin Šach 2025-03-17 12:53:53 +01:00 committed by Lukas Matena
parent f73d74146e
commit 5aa70f17e4

View File

@ -2351,7 +2351,7 @@ std::pair<GCode::SmoothPath, std::size_t> split_with_seam(
loop, flipped, scaled_resolution, *seam_point, seam_point_merge_distance_threshold loop, flipped, scaled_resolution, *seam_point, seam_point_merge_distance_threshold
), ),
0}; 0};
} else if (scarf != nullptr && scarf->start_point == scarf->end_point) { } else if (scarf != nullptr && scarf->start_point == scarf->end_point && !scarf->entire_loop) {
return {smooth_path_cache.resolve_or_fit_split_with_seam( return {smooth_path_cache.resolve_or_fit_split_with_seam(
loop, flipped, scaled_resolution, scarf->start_point, seam_point_merge_distance_threshold loop, flipped, scaled_resolution, scarf->start_point, seam_point_merge_distance_threshold
), 0}; ), 0};