mirror of
https://github.com/QIDITECH/QIDIStudio.git
synced 2026-02-03 02:18:41 +03:00
update
This commit is contained in:
13
lib/Slic3r/Polyline.pm
Normal file
13
lib/Slic3r/Polyline.pm
Normal file
@@ -0,0 +1,13 @@
|
||||
package Slic3r::Polyline;
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use Slic3r::Geometry qw(X Y);
|
||||
|
||||
sub new_scale {
|
||||
my $class = shift;
|
||||
my @points = map { ref($_) eq 'Slic3r::Point' ? $_->pp : $_ } @_;
|
||||
return $class->new(map [ Slic3r::Geometry::scale($_->[X]), Slic3r::Geometry::scale($_->[Y]) ], @points);
|
||||
}
|
||||
|
||||
1;
|
||||
Reference in New Issue
Block a user