Skip to content
Snippets Groups Projects
Commit eb021e88 authored by Karsten Rink's avatar Karsten Rink
Browse files

adjusted switch case for algorithm selection

parent dfe02d3d
No related branches found
No related tags found
No related merge requests found
...@@ -21,6 +21,8 @@ ...@@ -21,6 +21,8 @@
#include <limits> #include <limits>
#include <list> #include <list>
#include "logog/include/logog.hpp"
// BaseLib // BaseLib
#include "quicksort.h" #include "quicksort.h"
...@@ -205,12 +207,14 @@ bool isPointInTriangle(GeoLib::Point const& p, ...@@ -205,12 +207,14 @@ bool isPointInTriangle(GeoLib::Point const& p,
{ {
switch (algorithm) switch (algorithm)
{ {
case GeoLib::GAUSS:
return gaussPointInTriangle(p, a, b, c, eps_pnt_out_of_plane, eps_pnt_out_of_tri);
case GeoLib::BARYCENTRIC: case GeoLib::BARYCENTRIC:
return barycentricPointInTriangle(p, a, b, c, eps_pnt_out_of_plane, eps_pnt_out_of_tri); return barycentricPointInTriangle(p, a, b, c, eps_pnt_out_of_plane, eps_pnt_out_of_tri);
default: default:
return gaussPointInTriangle(p, a, b, c, eps_pnt_out_of_plane, eps_pnt_out_of_tri); ERR ("Selected algorithm for point in triangle testing not found, falling back on default.");
} }
return false; return gaussPointInTriangle(p, a, b, c, eps_pnt_out_of_plane, eps_pnt_out_of_tri);
} }
bool gaussPointInTriangle(GeoLib::Point const& q, bool gaussPointInTriangle(GeoLib::Point const& q,
......
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