Hollowing: allow to place drain holes on the inner surface of a hollowed cavity
Drain holes are not allowed to be placed on its own inner surface. This was recently (0e3ebb3)
done by forcing invalidation of the slaposDrillHoles, which also invalidates and therefore
hides the drilled mesh. However, that also hides the hollowed mesh and it is not possible
to place holes inside the cavity.
This change does not dump the drilled mesh, but checks that no raycast hit ends up in a hole.
This commit is contained in:
@@ -408,7 +408,14 @@ bool GLGizmoSlaSupports::unproject_on_mesh(const Vec2d& mouse_pos, std::pair<Vec
|
||||
// The raycaster query
|
||||
Vec3f hit;
|
||||
Vec3f normal;
|
||||
if (m_c->m_mesh_raycaster->unproject_on_mesh(mouse_pos, trafo.get_matrix(), camera, hit, normal, m_c->m_clipping_plane.get())) {
|
||||
if (m_c->m_mesh_raycaster->unproject_on_mesh(
|
||||
mouse_pos,
|
||||
trafo.get_matrix(),
|
||||
camera,
|
||||
hit,
|
||||
normal,
|
||||
m_c->m_clipping_plane_distance != 0.f ? m_c->m_clipping_plane.get() : nullptr))
|
||||
{
|
||||
// Check whether the hit is in a hole
|
||||
bool in_hole = false;
|
||||
// In case the hollowed and drilled mesh is available, we can allow
|
||||
|
||||
Reference in New Issue
Block a user