Only consider used extruders when limiting layer height. #2175
This commit is contained in:
parent
6f3bd72aeb
commit
e897fbbd51
2 changed files with 9 additions and 4 deletions
|
@ -256,10 +256,6 @@ sub validate {
|
|||
# --nozzle-diameter
|
||||
die "Invalid value for --nozzle-diameter\n"
|
||||
if grep $_ < 0, @{$self->nozzle_diameter};
|
||||
die "--layer-height can't be greater than --nozzle-diameter\n"
|
||||
if grep $self->layer_height > $_, @{$self->nozzle_diameter};
|
||||
die "First layer height can't be greater than --nozzle-diameter\n"
|
||||
if grep $self->get_value('first_layer_height') > $_, @{$self->nozzle_diameter};
|
||||
|
||||
# --perimeters
|
||||
die "Invalid value for --perimeters\n"
|
||||
|
|
|
@ -300,6 +300,15 @@ sub validate {
|
|||
die "The Spiral Vase option can only be used when printing single material objects.\n";
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
my $max_layer_height = max(
|
||||
map { $_->config->layer_height, $_->config->get_value('first_layer_height') } @{$self->objects},
|
||||
);
|
||||
my $extruders = $self->extruders;
|
||||
die "Layer height can't be greater than nozzle diameter\n"
|
||||
if grep { $max_layer_height > $self->config->get_at('nozzle_diameter', $_) } @$extruders;
|
||||
}
|
||||
}
|
||||
|
||||
# 0-based indices of used extruders
|
||||
|
|
Loading…
Reference in a new issue