ENH: do another map for ams filaments

1.If the group result differs little in flush,we will choose the one
that best fits the ams filaments

jira:NONE

Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Icd147b406e3494c841ef13564ad1b1231ad798fd
(cherry picked from commit 0b95bdd9d950918ea6979da6b4d62b2d2cd25b99)
This commit is contained in:
xun.zhang 2024-09-06 17:49:03 +08:00 committed by Noisyfox
parent 22d00f89b0
commit dcfa224cf2
5 changed files with 276 additions and 26 deletions

View file

@ -2132,7 +2132,7 @@ void Print::process(long long *time_cost_with_cache, bool use_cache)
auto map_mode = get_filament_map_mode();
// get recommended filament map
if (map_mode == FilamentMapMode::fmmAuto) {
filament_maps = ToolOrdering::get_recommended_filament_maps(all_filaments, &config(), physical_unprintables, geometric_unprintables);
filament_maps = ToolOrdering::get_recommended_filament_maps(all_filaments, &config(), this, physical_unprintables, geometric_unprintables);
std::transform(filament_maps.begin(), filament_maps.end(), filament_maps.begin(), [](int value) { return value + 1; });
update_filament_maps_to_config(filament_maps);
}