Consolidated all PlanePath classes in a single file
This commit is contained in:
parent
1485659726
commit
74f25ef52f
@ -3,14 +3,10 @@ use Moo;
|
||||
|
||||
use Slic3r::ExtrusionPath ':roles';
|
||||
use Slic3r::Fill::3DHoneycomb;
|
||||
use Slic3r::Fill::ArchimedeanChords;
|
||||
use Slic3r::Fill::Base;
|
||||
use Slic3r::Fill::Concentric;
|
||||
use Slic3r::Fill::Flowsnake;
|
||||
use Slic3r::Fill::HilbertCurve;
|
||||
use Slic3r::Fill::Honeycomb;
|
||||
use Slic3r::Fill::Line;
|
||||
use Slic3r::Fill::OctagramSpiral;
|
||||
use Slic3r::Fill::PlanePath;
|
||||
use Slic3r::Fill::Rectilinear;
|
||||
use Slic3r::Flow ':roles';
|
||||
|
@ -1,7 +0,0 @@
|
||||
package Slic3r::Fill::ArchimedeanChords;
|
||||
use Moo;
|
||||
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::ArchimedeanChords;
|
||||
|
||||
1;
|
@ -1,18 +0,0 @@
|
||||
package Slic3r::Fill::Flowsnake;
|
||||
use Moo;
|
||||
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
|
||||
use Math::PlanePath::Flowsnake;
|
||||
use Slic3r::Geometry qw(X);
|
||||
|
||||
# Sorry, this fill is currently broken.
|
||||
|
||||
sub process_polyline {
|
||||
my $self = shift;
|
||||
my ($polyline, $bounding_box) = @_;
|
||||
|
||||
$_->[X] += $bounding_box->center->[X] for @$polyline;
|
||||
}
|
||||
|
||||
1;
|
@ -1,7 +0,0 @@
|
||||
package Slic3r::Fill::HilbertCurve;
|
||||
use Moo;
|
||||
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::HilbertCurve;
|
||||
|
||||
1;
|
@ -1,9 +0,0 @@
|
||||
package Slic3r::Fill::OctagramSpiral;
|
||||
use Moo;
|
||||
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::OctagramSpiral;
|
||||
|
||||
sub multiplier () { sqrt(2) }
|
||||
|
||||
1;
|
@ -59,4 +59,42 @@ sub fill_surface {
|
||||
return { flow => $flow }, @paths;
|
||||
}
|
||||
|
||||
|
||||
package Slic3r::Fill::ArchimedeanChords;
|
||||
use Moo;
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::ArchimedeanChords;
|
||||
|
||||
|
||||
package Slic3r::Fill::Flowsnake;
|
||||
use Moo;
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::Flowsnake;
|
||||
use Slic3r::Geometry qw(X);
|
||||
|
||||
# Sorry, this fill is currently broken.
|
||||
|
||||
sub process_polyline {
|
||||
my $self = shift;
|
||||
my ($polyline, $bounding_box) = @_;
|
||||
|
||||
$_->[X] += $bounding_box->center->[X] for @$polyline;
|
||||
}
|
||||
|
||||
|
||||
package Slic3r::Fill::HilbertCurve;
|
||||
use Moo;
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::HilbertCurve;
|
||||
|
||||
|
||||
package Slic3r::Fill::OctagramSpiral;
|
||||
use Moo;
|
||||
extends 'Slic3r::Fill::PlanePath';
|
||||
use Math::PlanePath::OctagramSpiral;
|
||||
|
||||
sub multiplier () { sqrt(2) }
|
||||
|
||||
|
||||
|
||||
1;
|
||||
|
Loading…
Reference in New Issue
Block a user