From be9a3aed749d5b2664da821f4ec945b5b299b1cc Mon Sep 17 00:00:00 2001 From: gianpaolopalma Date: Mon, 27 Mar 2017 11:15:43 +0200 Subject: [PATCH] Bug fixing in the PickFace function Bug fixing in the projection of the vertices near to the plane of the projection point --- wrap/gl/pick.h | 1 + 1 file changed, 1 insertion(+) diff --git a/wrap/gl/pick.h b/wrap/gl/pick.h index 7d0c90a8..8fcae841 100644 --- a/wrap/gl/pick.h +++ b/wrap/gl/pick.h @@ -200,6 +200,7 @@ public: const CoordType &p1 = pVec[tri::Index(m, m.face[i].V(1))]; const CoordType &p2 = pVec[tri::Index(m, m.face[i].V(2))]; + if (!(abs(p0[2]) > 1 || abs(p1[2]) > 1 || abs(p2[2]) > 1) && IntersectionTriangleBox(reg, p0, p1, p2)) result.push_back(&m.face[i]); } }