mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2026-03-02 00:04:50 -07:00
FIX: backend get the extruder id based on filament_map
Change-Id: Ib7679c0fc67336e462467dab9f5b4d4684d6eb19 (cherry picked from commit dcd9fd501354da33baea2adc0f645fabe8880cf1)
This commit is contained in:
parent
f5d2a1bc0c
commit
8db3e3cd54
20 changed files with 193 additions and 131 deletions
|
|
@ -2603,6 +2603,15 @@ std::vector<int> Print::get_filament_maps() const
|
|||
return m_config.filament_map.values;
|
||||
}
|
||||
|
||||
size_t Print::get_extruder_id(unsigned int filament_id) const
|
||||
{
|
||||
std::vector<int> filament_map = get_filament_maps();
|
||||
if (filament_id < filament_map.size()) {
|
||||
return filament_map[filament_id];
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Wipe tower support.
|
||||
bool Print::has_wipe_tower() const
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue