diff options
Diffstat (limited to 'core/math/delaunay_3d.h')
-rw-r--r-- | core/math/delaunay_3d.h | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/core/math/delaunay_3d.h b/core/math/delaunay_3d.h index 0976d8556f..8fdb52556f 100644 --- a/core/math/delaunay_3d.h +++ b/core/math/delaunay_3d.h @@ -55,7 +55,6 @@ class Delaunay3D { }; struct Simplex { - uint32_t points[4]; R128 circum_center_x; R128 circum_center_y; @@ -104,7 +103,6 @@ class Delaunay3D { }; _FORCE_INLINE_ static void circum_sphere_compute(const Vector3 *p_points, Simplex *p_simplex) { - // the only part in the algorithm where there may be precision errors is this one, so ensure that // we do it as maximum precision as possible @@ -164,7 +162,6 @@ class Delaunay3D { } _FORCE_INLINE_ static bool simplex_contains(const Vector3 *p_points, const Simplex &p_simplex, uint32_t p_vertex) { - R128 v_x = p_points[p_vertex].x; R128 v_y = p_points[p_vertex].y; R128 v_z = p_points[p_vertex].z; @@ -179,7 +176,6 @@ class Delaunay3D { } static bool simplex_is_coplanar(const Vector3 *p_points, const Simplex &p_simplex) { - Plane p(p_points[p_simplex.points[0]], p_points[p_simplex.points[1]], p_points[p_simplex.points[2]]); if (ABS(p.distance_to(p_points[p_simplex.points[3]])) < CMP_EPSILON) { return true; @@ -216,7 +212,6 @@ public: }; static Vector<OutputSimplex> tetrahedralize(const Vector<Vector3> &p_points) { - uint32_t point_count = p_points.size(); Vector3 *points = (Vector3 *)memalloc(sizeof(Vector3) * (point_count + 4)); @@ -273,7 +268,6 @@ public: LocalVector<Triangle> triangles; for (uint32_t i = 0; i < point_count; i++) { - bool unique = true; for (uint32_t j = i + 1; j < point_count; j++) { if (points[i].is_equal_approx(points[j])) { @@ -296,7 +290,6 @@ public: Simplex *simplex = E->get(); if (simplex_contains(points, *simplex, i)) { - static const uint32_t triangle_order[4][3] = { { 0, 1, 2 }, { 0, 1, 3 }, @@ -329,7 +322,6 @@ public: uint32_t good_triangles = 0; for (uint32_t j = 0; j < triangles.size(); j++) { - if (triangles[j].bad) { continue; } |