Skip to content
Snippets Groups Projects
Commit 76662514 authored by Andrew Wilson's avatar Andrew Wilson :elephant:
Browse files

Remove unused/incomplete function

parent ec4d1272
No related branches found
No related tags found
No related merge requests found
......@@ -240,29 +240,6 @@ closestPointOnTriangle(const Vec3d& p, const Vec3d& a, const Vec3d& b, const Vec
return a + ab * v + ac * w; // = u*a + v*b + w*c, u = va * denom = 1.0f-v-w
}
void
closestPointOnTriangleLine(
const Vec3d& a, const Vec3d& b, const Vec3d& c,
const Vec3d& p, const Vec3d& q,
Vec3d& triangleClosestPt, Vec3d& lineClosestPt)
{
// First compute plane point intersection point
const Vec3d triangleN = (b - a).cross(c - a);
Vec3d iPt;
if (testPlaneLine(p, q, a, triangleN, iPt))
{
// Test if inside the triangle
const Vec3d bCoords = baryCentric(a, b, c, iPt);
if (bCoords[0] >= 0.0 && bCoords[1] >= 0.0 && bCoords[2] >= 0.0)
{
// If we are inside the triangle return that point
lineClosestPt = triangleClosestPt = iPt;
return;
}
}
// triangle and line are parallel
}
int
triangleToTriangle(
const Vec3i& tri_a, const Vec3i& tri_b,
......
......@@ -692,14 +692,6 @@ testSegmentTriangle(
///
Vec3d closestPointOnTriangle(const Vec3d& p, const Vec3d& a, const Vec3d& b, const Vec3d& c, int& caseType);
///
/// \brief Returns the closest point pair on the triangle and line
///
void closestPointOnTriangleLine(
const Vec3d& a, const Vec3d& b, const Vec3d& c,
const Vec3d& p, const Vec3d& q,
Vec3d& triangleClosestPt, Vec3d& lineClosestPt);
///
/// \brief Check if sphere and triangle intersect, with point direction contact info
/// \return true if intersecting, false if not
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment