mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 16:57:53 -06:00
parent
90d8da0e0d
commit
aba7641fe4
2 changed files with 29 additions and 3 deletions
|
@ -7,7 +7,7 @@ use parent 'Slic3r::Polyline';
|
|||
|
||||
use Slic3r::Geometry qw(polygon_lines polygon_remove_parallel_continuous_edges
|
||||
polygon_remove_acute_vertices polygon_segment_having_point point_in_polygon
|
||||
X1 X2 Y1 Y2);
|
||||
PI X1 X2 Y1 Y2);
|
||||
use Slic3r::Geometry::Clipper qw(JT_MITER);
|
||||
|
||||
sub lines {
|
||||
|
@ -154,4 +154,12 @@ sub split_at_first_point {
|
|||
return $self->split_at_index(0);
|
||||
}
|
||||
|
||||
sub concave_points {
|
||||
my $self = shift;
|
||||
|
||||
return map $self->[$_],
|
||||
grep Slic3r::Geometry::angle3points(@$self[$_, $_-1, $_+1]) < PI,
|
||||
-1 .. ($#$self-1);
|
||||
}
|
||||
|
||||
1;
|
Loading…
Add table
Add a link
Reference in a new issue