Relax collision checks when Detect thin walls is disabled
This commit is contained in:
parent
a02ea2842c
commit
79d55efa0e
1 changed files with 25 additions and 11 deletions
|
@ -105,11 +105,18 @@ sub make_perimeters {
|
||||||
if ($i == 1) {
|
if ($i == 1) {
|
||||||
# the minimum thickness of a single loop is:
|
# the minimum thickness of a single loop is:
|
||||||
# ext_width/2 + ext_spacing/2 + spacing/2 + width/2
|
# ext_width/2 + ext_spacing/2 + spacing/2 + width/2
|
||||||
|
if ($self->config->thin_walls) {
|
||||||
@offsets = @{offset2(
|
@offsets = @{offset2(
|
||||||
\@last,
|
\@last,
|
||||||
-(0.5*$ext_pwidth + 0.5*$ext_min_spacing - 1),
|
-(0.5*$ext_pwidth + 0.5*$ext_min_spacing - 1),
|
||||||
+(0.5*$ext_min_spacing - 1),
|
+(0.5*$ext_min_spacing - 1),
|
||||||
)};
|
)};
|
||||||
|
} else {
|
||||||
|
@offsets = @{offset(
|
||||||
|
\@last,
|
||||||
|
-0.5*$ext_pwidth,
|
||||||
|
)};
|
||||||
|
}
|
||||||
|
|
||||||
# look for thin walls
|
# look for thin walls
|
||||||
if ($self->config->thin_walls) {
|
if ($self->config->thin_walls) {
|
||||||
|
@ -123,11 +130,18 @@ sub make_perimeters {
|
||||||
} else {
|
} else {
|
||||||
my $distance = ($i == 2) ? $ext_pspacing : $pspacing;
|
my $distance = ($i == 2) ? $ext_pspacing : $pspacing;
|
||||||
|
|
||||||
|
if ($self->config->thin_walls) {
|
||||||
@offsets = @{offset2(
|
@offsets = @{offset2(
|
||||||
\@last,
|
\@last,
|
||||||
-($distance + 0.5*$min_spacing - 1),
|
-($distance + 0.5*$min_spacing - 1),
|
||||||
+(0.5*$min_spacing - 1),
|
+(0.5*$min_spacing - 1),
|
||||||
)};
|
)};
|
||||||
|
} else {
|
||||||
|
@offsets = @{offset(
|
||||||
|
\@last,
|
||||||
|
-$distance,
|
||||||
|
)};
|
||||||
|
}
|
||||||
|
|
||||||
# look for gaps
|
# look for gaps
|
||||||
if ($self->region->config->gap_fill_speed > 0 && $self->config->fill_density > 0) {
|
if ($self->region->config->gap_fill_speed > 0 && $self->config->fill_density > 0) {
|
||||||
|
|
Loading…
Reference in a new issue