WIP: Added a circle cursor and naive logic to select triangles inside

Deselection is possible when holding shift
Triangles obscured by the mesh are selected nonetheless (so far)
This commit is contained in:
Lukas Matena 2019-10-08 10:15:06 +02:00
parent 08daddb5de
commit 2e71dcefc3
4 changed files with 141 additions and 23 deletions

View file

@ -113,6 +113,9 @@ public:
: m_emesh(mesh)
{}
void line_from_mouse_pos(const Vec2d& mouse_pos, const Transform3d& trafo, const Camera& camera,
Vec3d& point, Vec3d& direction) const;
// Given a mouse position, this returns true in case it is on the mesh.
bool unproject_on_mesh(
const Vec2d& mouse_pos,