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/tests
diff options
context:
space:
mode:
authortamasmeszaros <meszaros.q@gmail.com>2020-01-13 16:00:33 +0300
committertamasmeszaros <meszaros.q@gmail.com>2020-01-14 12:48:22 +0300
commit256249fdaf065fd3bea1c95f277e9369e92d3862 (patch)
tree3d9f5b9882f55b21e8b701c3f1b4739d848ebfc2 /tests
parent6205524d75e47ebb32ba999525121c3647cd151a (diff)
Make sla support pierce tests repeatable
Diffstat (limited to 'tests')
-rw-r--r--tests/sla_print/sla_test_utils.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/sla_print/sla_test_utils.cpp b/tests/sla_print/sla_test_utils.cpp
index 3da28a50e..124fa3cf1 100644
--- a/tests/sla_print/sla_test_utils.cpp
+++ b/tests/sla_print/sla_test_utils.cpp
@@ -115,8 +115,10 @@ void test_supports(const std::string &obj_filename,
// Create the support point generator
sla::SupportPointGenerator::Config autogencfg;
autogencfg.head_diameter = float(2 * supportcfg.head_front_radius_mm);
- sla::SupportPointGenerator point_gen{emesh, out.model_slices, out.slicegrid,
- autogencfg, [] {}, [](int) {}};
+ sla::SupportPointGenerator point_gen{emesh, autogencfg, [] {}, [](int) {}};
+
+ long seed = 0; // Make the test repeatable
+ point_gen.execute(out.model_slices, out.slicegrid, seed);
// Get the calculated support points.
std::vector<sla::SupportPoint> support_points = point_gen.output();