mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-13 01:37:53 -06:00
WIP: Moving ownership of PrintRegions to PrintObjects.
This commit is contained in:
parent
d21b9aa089
commit
714149dab2
9 changed files with 184 additions and 175 deletions
|
@ -223,11 +223,11 @@ void ToolOrdering::collect_extruders(const PrintObject &object, const std::vecto
|
|||
layer_tools.extruder_override = extruder_override;
|
||||
|
||||
// What extruders are required to print this object layer?
|
||||
for (size_t region_id = 0; region_id < object.region_volumes.size(); ++ region_id) {
|
||||
for (size_t region_id = 0; region_id < object.num_printing_regions(); ++ region_id) {
|
||||
const LayerRegion *layerm = (region_id < layer->regions().size()) ? layer->regions()[region_id] : nullptr;
|
||||
if (layerm == nullptr)
|
||||
continue;
|
||||
const PrintRegion ®ion = *object.print()->regions()[region_id];
|
||||
const PrintRegion ®ion = *layerm->region();
|
||||
|
||||
if (! layerm->perimeters.entities.empty()) {
|
||||
bool something_nonoverriddable = true;
|
||||
|
@ -689,8 +689,8 @@ float WipingExtrusions::mark_wiping_extrusions(const Print& print, unsigned int
|
|||
// iterate through copies (aka PrintObject instances) first, so that we mark neighbouring infills to minimize travel moves
|
||||
for (unsigned int copy = 0; copy < num_of_copies; ++copy) {
|
||||
|
||||
for (size_t region_id = 0; region_id < object->region_volumes.size(); ++ region_id) {
|
||||
const auto& region = *object->print()->regions()[region_id];
|
||||
for (size_t region_id = 0; region_id < object->num_printing_regions(); ++ region_id) {
|
||||
const PrintRegion ®ion = object->printing_region(region_id);
|
||||
|
||||
if (!region.config().wipe_into_infill && !object->config().wipe_into_objects)
|
||||
continue;
|
||||
|
@ -762,8 +762,8 @@ void WipingExtrusions::ensure_perimeters_infills_order(const Print& print)
|
|||
size_t num_of_copies = object->instances().size();
|
||||
|
||||
for (size_t copy = 0; copy < num_of_copies; ++copy) { // iterate through copies first, so that we mark neighbouring infills to minimize travel moves
|
||||
for (size_t region_id = 0; region_id < object->region_volumes.size(); ++ region_id) {
|
||||
const auto& region = *object->print()->regions()[region_id];
|
||||
for (size_t region_id = 0; region_id < object->num_printing_regions(); ++ region_id) {
|
||||
const auto& region = object->printing_region(region_id);
|
||||
|
||||
if (!region.config().wipe_into_infill && !object->config().wipe_into_objects)
|
||||
continue;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue