mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-23 06:33:57 -06:00
Finished porting BoundingBox to XS
This commit is contained in:
parent
ea47f3b6e7
commit
b17d06f9d1
24 changed files with 160 additions and 262 deletions
|
@ -19,7 +19,7 @@ sub wkt {
|
|||
|
||||
sub bounding_box {
|
||||
my $self = shift;
|
||||
return Slic3r::Geometry::BoundingBox->new_from_points($self);
|
||||
return Slic3r::Geometry::BoundingBox->new_from_points([ @$self ]);
|
||||
}
|
||||
|
||||
sub size {
|
||||
|
@ -27,10 +27,4 @@ sub size {
|
|||
return [ Slic3r::Geometry::size_2D($self) ];
|
||||
}
|
||||
|
||||
sub align_to_origin {
|
||||
my $self = shift;
|
||||
my $bb = $self->bounding_box;
|
||||
return $self->translate(-$bb->x_min, -$bb->y_min);
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue