mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-08-08 14:34:04 -06:00
Use XS Point everywhere
This commit is contained in:
parent
d0701cdcd4
commit
9af2a1c007
37 changed files with 238 additions and 303 deletions
|
@ -25,16 +25,15 @@ use Slic3r;
|
|||
[0,0],[1,0],[2,0],[2,1],[2,2],[1,2],[0,2],[0,1],[0,0],
|
||||
);
|
||||
$polyline = $polyline->simplify(1);
|
||||
is_deeply $polyline, [ [0, 0], [2, 0], [2, 2], [0, 2], [0, 0] ], 'Douglas-Peucker';
|
||||
is_deeply $polyline->arrayref_pp, [ [0, 0], [2, 0], [2, 2], [0, 2], [0, 0] ], 'Douglas-Peucker';
|
||||
}
|
||||
|
||||
{
|
||||
my $polyline = Slic3r::Polyline->new(
|
||||
[0,0],[0.5,0.5],[1,0],[1.25,-0.25],[1.5,.5],
|
||||
[0,0], [50,50], [100,0], [125,-25], [150,50],
|
||||
);
|
||||
$polyline->scale(100);
|
||||
$polyline = $polyline->simplify(25);
|
||||
is_deeply $polyline, [ [0, 0], [50, 50], [125, -25], [150, 50] ], 'Douglas-Peucker';
|
||||
is_deeply $polyline->arrayref_pp, [ [0, 0], [50, 50], [125, -25], [150, 50] ], 'Douglas-Peucker';
|
||||
}
|
||||
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue