mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 15:07:31 -06:00
ENH: should apply instance shift in is_through_overhang
Signed-off-by: salt.wei <salt.wei@bambulab.com> Change-Id: I07ca04d459c3e98650c8e5a33f56dac20f99b9a2
This commit is contained in:
parent
c00719b837
commit
bc0273d734
4 changed files with 53 additions and 30 deletions
|
@ -437,7 +437,7 @@ bool Print::has_brim() const
|
|||
}
|
||||
|
||||
//BBS
|
||||
std::vector<size_t> Print::layers_sorted_for_object(float start, float end, std::vector<LayerPtrs> &layers_of_objects, std::vector<BoundingBox> &boundingBox_for_objects)
|
||||
std::vector<size_t> Print::layers_sorted_for_object(float start, float end, std::vector<LayerPtrs> &layers_of_objects, std::vector<BoundingBox> &boundingBox_for_objects, std::vector<Points> &objects_instances_shift)
|
||||
{
|
||||
std::vector<size_t> idx_of_object_sorted;
|
||||
size_t idx = 0;
|
||||
|
@ -448,6 +448,11 @@ std::vector<size_t> Print::layers_sorted_for_object(float start, float end, std:
|
|||
std::sort(idx_of_object_sorted.begin(), idx_of_object_sorted.end(),
|
||||
[boundingBox_for_objects](auto left, auto right) { return boundingBox_for_objects[left].area() > boundingBox_for_objects[right].area(); });
|
||||
|
||||
objects_instances_shift.clear();
|
||||
objects_instances_shift.reserve(m_objects.size());
|
||||
for (const auto& object : m_objects)
|
||||
objects_instances_shift.emplace_back(object->get_instances_shift_without_plate_offset());
|
||||
|
||||
return idx_of_object_sorted;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue