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:
authortamasmeszaros <meszaros.q@gmail.com>2019-02-08 14:30:10 +0300
committertamasmeszaros <meszaros.q@gmail.com>2019-02-08 14:30:10 +0300
commit8b2a8822d250fe5ee78f98ae1c8b55029c39d173 (patch)
tree4d996e152906beeecf3aa39d48425f49b399e3ad
parent29137d1b3c2d64cf74bc21fb3c975309e35bcb7e (diff)
Partial fix for crashing min_obj_distance
-rw-r--r--src/libslic3r/Print.cpp3
-rw-r--r--src/slic3r/GUI/Plater.cpp7
2 files changed, 8 insertions, 2 deletions
diff --git a/src/libslic3r/Print.cpp b/src/libslic3r/Print.cpp
index bc692ca90..6416a709a 100644
--- a/src/libslic3r/Print.cpp
+++ b/src/libslic3r/Print.cpp
@@ -1137,6 +1137,9 @@ std::string Print::validate() const
// Apply the same transformations we apply to the actual meshes when slicing them.
object->model_object()->instances.front()->transform_polygon(&convex_hull);
// Grow convex hull with the clearance margin.
+ // FIXME: Arrangement has different parameters for offsetting (jtMiter, limit 2)
+ // which causes that the warning will be showed after arrangement with the
+ // appropriate object distance. Even if I set this to jtMiter the warning still shows up.
convex_hull = offset(convex_hull, scale_(m_config.extruder_clearance_radius.value)/2, jtRound, scale_(0.1)).front();
// Now we check that no instance of convex_hull intersects any of the previously checked object instances.
for (const Point &copy : object->m_copies) {
diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp
index 1968dad69..774e61024 100644
--- a/src/slic3r/GUI/Plater.cpp
+++ b/src/slic3r/GUI/Plater.cpp
@@ -1092,7 +1092,7 @@ Plater::priv::priv(Plater *q, MainFrame *main_frame)
: q(q)
, main_frame(main_frame)
, config(Slic3r::DynamicPrintConfig::new_from_defaults_keys({
- "bed_shape", "complete_objects", "extruder_clearance_radius", "skirts", "skirt_distance",
+ "bed_shape", "complete_objects", "duplicate_distance", "extruder_clearance_radius", "skirts", "skirt_distance",
"brim_width", "variable_layer_height", "serial_port", "serial_speed", "host_type", "print_host",
"printhost_apikey", "printhost_cafile", "nozzle_diameter", "single_extruder_multi_material",
"wipe_tower", "wipe_tower_x", "wipe_tower_y", "wipe_tower_width", "wipe_tower_rotation_angle",
@@ -1774,8 +1774,11 @@ void Plater::priv::arrange()
// FIXME: I don't know how to obtain the minimum distance, it depends
// on printer technology. I guess the following should work but it crashes.
double dist = 6; //PrintConfig::min_object_distance(config);
+ if(printer_technology == ptFFF) {
+ dist = PrintConfig::min_object_distance(config);
+ }
- auto min_obj_distance = static_cast<coord_t>(dist/SCALING_FACTOR);
+ auto min_obj_distance = coord_t(dist/SCALING_FACTOR);
const auto *bed_shape_opt = config->opt<ConfigOptionPoints>("bed_shape");