Further fixes of the first_layer_height refactoring.

This commit is contained in:
Vojtech Bubnik 2021-04-21 14:34:43 +02:00
parent 4ce7ea40f0
commit 0c1953a929
6 changed files with 16 additions and 21 deletions

View file

@ -64,9 +64,9 @@ SlicingParameters SlicingParameters::create_from_config(
coordf_t object_height,
const std::vector<unsigned int> &object_extruders)
{
assert(! print_config.first_layer_height.percent);
coordf_t first_layer_height = (print_config.first_layer_height.value <= 0) ?
object_config.layer_height.value :
print_config.first_layer_height.get_abs_value(object_config.layer_height.value);
object_config.layer_height.value : print_config.first_layer_height.value;
// If object_config.support_material_extruder == 0 resp. object_config.support_material_interface_extruder == 0,
// print_config.nozzle_diameter.get_at(size_t(-1)) returns the 0th nozzle diameter,
// which is consistent with the requirement that if support_material_extruder == 0 resp. support_material_interface_extruder == 0,