Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlessandro Ranellucci <aar@cpan.org>2011-11-30 20:48:00 +0400
committerAlessandro Ranellucci <aar@cpan.org>2011-11-30 20:48:00 +0400
commit71c359bb2990ea8f044323db377d2814ef4e53bf (patch)
treece0e3947838c46ab1614180f896498ba94de3f48 /lib/Slic3r/TriangleMesh.pm
parent42383dec847fcdfd04ce2a0122b580cd5c8615b9 (diff)
Cleaning recent changes
Diffstat (limited to 'lib/Slic3r/TriangleMesh.pm')
-rw-r--r--lib/Slic3r/TriangleMesh.pm14
1 files changed, 4 insertions, 10 deletions
diff --git a/lib/Slic3r/TriangleMesh.pm b/lib/Slic3r/TriangleMesh.pm
index 3ef1baf3e..fd7c1c253 100644
--- a/lib/Slic3r/TriangleMesh.pm
+++ b/lib/Slic3r/TriangleMesh.pm
@@ -2,7 +2,7 @@ package Slic3r::TriangleMesh;
use Moo;
use Slic3r::Geometry qw(X Y Z A B PI epsilon same_point points_coincide angle3points
- merge_collinear_lines);
+ merge_collinear_lines nearest_point);
use XXX;
has 'facets' => (is => 'ro', default => sub { [] });
@@ -132,8 +132,8 @@ sub make_loops {
}
$next_lines
- or die sprintf("No lines start at point %s. This shouldn't happen. Please check the model for manifoldness.\n", $get_point_id->($points[-1]));
- last CYCLE if !@$next_lines;
+ or printf("No lines start at point %s. This shouldn't happen. Please check the model for manifoldness.\n", $get_point_id->($points[-1]));
+ last CYCLE if !$next_lines or !@$next_lines;
my @ordered_next_lines = sort
{ angle3points($points[-1], $points[-2], $next_lines->[$a][B]) <=> angle3points($points[-1], $points[-2], $next_lines->[$b][B]) }
@@ -339,13 +339,7 @@ sub _facet {
for (my $layer_id = $min_layer; $layer_id <= $max_layer; $layer_id++) {
my $layer = $print->layer($layer_id);
- my @intersections = $self->intersect_facet($facet_index, \@vertices, $layer->slice_z);
- if ($facet_index =~ /^(488)$/ && $layer_id == 14) {
- printf "z = %f\n", $layer->slice_z;
- YYY \@intersections;
- #exit if $facet_index == 488;
- }
- $layer->add_line($_) for @intersections;
+ $layer->add_line($_) for $self->intersect_facet($facet_index, \@vertices, $layer->slice_z);
}
}