mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-15 02:37:51 -06:00
More work for step-based slicing
This commit is contained in:
parent
5280b05ebb
commit
685e8e4dfa
2 changed files with 74 additions and 64 deletions
|
@ -273,6 +273,11 @@ sub slice {
|
|||
$self->layers->[$i]->id($i);
|
||||
}
|
||||
}
|
||||
|
||||
# simplify slices if required
|
||||
if ($self->config->resolution) {
|
||||
$self->_simplify_slices(scale($self->config->resolution));
|
||||
}
|
||||
}
|
||||
|
||||
sub make_perimeters {
|
||||
|
@ -348,6 +353,11 @@ sub make_perimeters {
|
|||
$_->make_perimeters for @{$self->layers};
|
||||
},
|
||||
);
|
||||
|
||||
# simplify slices (both layer and region slices),
|
||||
# we only need the max resolution for perimeters
|
||||
### This makes this method not-idempotent, so we keep it disabled for now.
|
||||
###$self->_simplify_slices(&Slic3r::SCALED_RESOLUTION);
|
||||
}
|
||||
|
||||
sub detect_surfaces_type {
|
||||
|
@ -850,4 +860,13 @@ sub generate_support_material {
|
|||
->generate($self);
|
||||
}
|
||||
|
||||
sub _simplify_slices {
|
||||
my ($self, $distance) = @_;
|
||||
|
||||
foreach my $layer (@{$self->layers}) {
|
||||
$layer->slices->simplify($distance);
|
||||
$_->slices->simplify($distance) for @{$layer->regions};
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue