#7010 - Fixed import from 3mf containing modifiers crossing the printbed

This commit is contained in:
enricoturri1966 2021-09-27 09:45:54 +02:00
parent 2356c30356
commit 117df134f6

View File

@ -2438,7 +2438,7 @@ std::vector<size_t> Plater::priv::load_files(const std::vector<fs::path>& input_
for (ModelObject* model_object : model.objects) {
if (!type_3mf && !type_zip_amf)
model_object->center_around_origin(false);
model_object->ensure_on_bed(is_project_file);
model_object->ensure_on_bed(is_project_file || type_3mf || type_zip_amf);
}
// check multi-part object adding for the SLA-printing
@ -2455,7 +2455,7 @@ std::vector<size_t> Plater::priv::load_files(const std::vector<fs::path>& input_
if (one_by_one) {
if (type_3mf && !is_project_file)
model.center_instances_around_point(bed_shape_bb().center());
auto loaded_idxs = load_model_objects(model.objects, is_project_file);
auto loaded_idxs = load_model_objects(model.objects, is_project_file || type_3mf || type_zip_amf);
obj_idxs.insert(obj_idxs.end(), loaded_idxs.begin(), loaded_idxs.end());
} else {
// This must be an .stl or .obj file, which may contain a maximum of one volume.