mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-23 14:44:19 -06:00
Extrusion of perimeters
This commit is contained in:
parent
55a523e1fa
commit
febd655e22
11 changed files with 206 additions and 5 deletions
|
@ -1,6 +1,7 @@
|
|||
package Slic3r::Surface;
|
||||
use Moose;
|
||||
|
||||
use Math::Geometry::Planar;
|
||||
use Moose::Util::TypeConstraints;
|
||||
|
||||
has 'contour' => (
|
||||
|
@ -55,4 +56,12 @@ sub encloses_point {
|
|||
return 1;
|
||||
}
|
||||
|
||||
sub mgp_polygon {
|
||||
my $self = shift;
|
||||
|
||||
my $p = Math::Geometry::Planar->new;
|
||||
$p->polygons([ map $_->points, $self->contour->mgp_polygon, map($_->mgp_polygon, @{ $self->holes }) ]);
|
||||
return $p;
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue