Merge branch 'master' of https://github.com/prusa3d/Slic3r into et_canvas_gui_refactoring
Before Width: | Height: | Size: 144 KiB |
Before Width: | Height: | Size: 364 KiB |
Before Width: | Height: | Size: 398 KiB |
Before Width: | Height: | Size: 794 KiB |
Before Width: | Height: | Size: 63 KiB |
Before Width: | Height: | Size: 159 KiB |
Before Width: | Height: | Size: 143 KiB |
Before Width: | Height: | Size: 361 KiB |
Before Width: | Height: | Size: 396 KiB |
Before Width: | Height: | Size: 790 KiB |
Before Width: | Height: | Size: 63 KiB |
Before Width: | Height: | Size: 159 KiB |
Before Width: | Height: | Size: 105 KiB |
Before Width: | Height: | Size: 277 KiB |
Before Width: | Height: | Size: 324 KiB |
Before Width: | Height: | Size: 674 KiB |
Before Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 20 KiB |
@ -556,29 +556,7 @@ ShapeData2D projectModelFromTop(const Slic3r::Model &model) {
|
||||
// TODO export the exact 2D projection. Cannot do it as libnest2d
|
||||
// does not support concave shapes (yet).
|
||||
ClipperLib::Path clpath;
|
||||
//WIP Vojtech's optimization of the calculation of the convex hull is not working correctly yet.
|
||||
#if 1
|
||||
{
|
||||
TriangleMesh rmesh = objptr->raw_mesh();
|
||||
|
||||
ModelInstance * finst = objptr->instances.front();
|
||||
|
||||
// Object instances should carry the same scaling and
|
||||
// x, y rotation that is why we use the first instance.
|
||||
// The next line will apply only the full mirroring and scaling
|
||||
rmesh.transform(finst->get_matrix(true, true, false, false));
|
||||
rmesh.rotate_x(float(finst->get_rotation()(X)));
|
||||
rmesh.rotate_y(float(finst->get_rotation()(Y)));
|
||||
|
||||
// TODO export the exact 2D projection. Cannot do it as libnest2d
|
||||
// does not support concave shapes (yet).
|
||||
auto p = rmesh.convex_hull();
|
||||
|
||||
p.make_clockwise();
|
||||
p.append(p.first_point());
|
||||
clpath = Slic3rMultiPoint_to_ClipperPath(p);
|
||||
}
|
||||
#else
|
||||
// Object instances should carry the same scaling and
|
||||
// x, y rotation that is why we use the first instance.
|
||||
{
|
||||
@ -593,7 +571,6 @@ ShapeData2D projectModelFromTop(const Slic3r::Model &model) {
|
||||
p.append(p.first_point());
|
||||
clpath = Slic3rMultiPoint_to_ClipperPath(p);
|
||||
}
|
||||
#endif
|
||||
|
||||
for(ModelInstance* objinst : objptr->instances) {
|
||||
if(objinst) {
|
||||
|