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
path: root/t
diff options
context:
space:
mode:
authorVojtech Bubnik <bubnikv@gmail.com>2020-12-09 18:37:44 +0300
committerVojtech Bubnik <bubnikv@gmail.com>2020-12-09 18:37:44 +0300
commit11b4b3f4f94fd75e77a27aadd8b2bf5a7d863ac7 (patch)
tree27ab349ef77b97bb40e0e8c8cb6af394433cf108 /t
parentfb7098e542f12864821585b2e248ba1cf5123d26 (diff)
Fixing vase mode Perl tests.
Diffstat (limited to 't')
-rw-r--r--t/shells.t9
1 files changed, 8 insertions, 1 deletions
diff --git a/t/shells.t b/t/shells.t
index c40131590..47b5c8881 100644
--- a/t/shells.t
+++ b/t/shells.t
@@ -234,6 +234,7 @@ use Slic3r::Test;
$config->set('first_layer_height', '100%');
$config->set('layer_height', 0.4);
$config->set('start_gcode', '');
+# $config->set('use_relative_e_distances', 1);
$config->validate;
my $print = Slic3r::Test::init_print('20mm_cube', config => $config);
@@ -269,7 +270,12 @@ use Slic3r::Test;
my $total_dist_XY = sum(map $_->[1], @this_layer);
$sum_of_partial_z_equals_to_layer_height = 1
- if abs(sum(map $_->[0], @this_layer) - $config->layer_height) > epsilon;
+ if abs(sum(map $_->[0], @this_layer) - $config->layer_height) >
+ # The first segment on the 2nd layer has extrusion interpolated from zero
+ # and the 1st segment has such a low extrusion assigned, that it is effectively zero, thus the move
+ # is considered non-extruding and a higher epsilon is required.
+ ($z_moves == 2 ? 0.0021 : epsilon);
+ #printf ("Total height: %f, layer height: %f, good: %d\n", sum(map $_->[0], @this_layer), $config->layer_height, $sum_of_partial_z_equals_to_layer_height);
foreach my $segment (@this_layer) {
# check that segment's dist_Z is proportioned to its dist_XY
@@ -281,6 +287,7 @@ use Slic3r::Test;
} elsif ($info->{extruding} && $info->{dist_XY} > 0) {
$horizontal_extrusions = 1
if $info->{dist_Z} == 0;
+ #printf("Pushing dist_z: %f, dist_xy: %f\n", $info->{dist_Z}, $info->{dist_XY});
push @this_layer, [ $info->{dist_Z}, $info->{dist_XY} ];
}
}