1
0
mirror of https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git synced 2026-07-20 09:34:26 +00:00

Ported ExPolygon->area()

This commit is contained in:
Alessandro Ranellucci
2013-08-26 22:50:26 +02:00
parent 792fcba7be
commit 706851f836
7 changed files with 19 additions and 12 deletions
-7
View File
@@ -126,13 +126,6 @@ sub simplify {
return @{ Slic3r::Geometry::Clipper::union_ex([ $self->simplify_as_polygons($tolerance) ]) };
}
sub area {
my $self = shift;
my $area = $self->contour->area;
$area -= $_->area for $self->holes;
return $area;
}
# this method only works for expolygons having only a contour or
# a contour and a hole, and not being thicker than the supplied
# width. it returns a polyline or a polygon