ENH: Change the collision calculation

of the wipe tower's outer wall to use the actual outer wall path.

jira: none
Change-Id: Ib45ecbc328c88c1abe6d9e8567f715331a3ddd37
(cherry picked from commit 0a20f1fe6d6d63cdcb13bc19fd9ae553f45b6f59)
This commit is contained in:
jiangkai.zhao
2025-02-10 15:58:34 +08:00
committed by Noisyfox
parent f133dd1733
commit d463858fda
5 changed files with 49 additions and 39 deletions

View File

@@ -2269,7 +2269,6 @@ void Print::process(long long *time_cost_with_cache, bool use_cache)
std::optional<const FakeWipeTower *> wipe_tower_opt = {};
if (this->has_wipe_tower()) {
m_fake_wipe_tower.set_pos({m_config.wipe_tower_x.get_at(m_plate_index), m_config.wipe_tower_y.get_at(m_plate_index)});
m_fake_wipe_tower.set_bbx();
wipe_tower_opt = std::make_optional<const FakeWipeTower *>(&m_fake_wipe_tower);
}
auto conflictRes = ConflictChecker::find_inter_of_lines_in_diff_objs(m_objects, wipe_tower_opt);
@@ -3044,7 +3043,7 @@ void Print::_make_wipe_tower()
m_fake_wipe_tower.set_fake_extrusion_data(wipe_tower.position(), wipe_tower.width(), wipe_tower.get_height(),
wipe_tower.get_layer_height(), m_wipe_tower_data.depth, m_wipe_tower_data.brim_width,
{scale_(origin.x()), scale_(origin.y())});
m_fake_wipe_tower.real_bbx = wipe_tower.get_bbx();
m_fake_wipe_tower.outer_wall = wipe_tower.get_outer_wall();
} else {
// Get wiping matrix to get number of extruders and convert vector<double> to vector<float>:
std::vector<float> flush_matrix(cast<float>(m_config.flush_volumes_matrix.values));