diff options
author | Morris Tabor <80684659+mortarroad@users.noreply.github.com> | 2021-05-21 09:58:01 +0200 |
---|---|---|
committer | Morris Tabor <80684659+mortarroad@users.noreply.github.com> | 2021-05-22 22:35:42 +0200 |
commit | d1bc88d426b3751a37beb9c81513ccd16c7e2860 (patch) | |
tree | 96b3ab3d650a4910c84523ed0e7e475572ee1cca /modules/gdnavigation/navigation_mesh_generator.cpp | |
parent | d5f9f58b61c2430ee5fae59a0366581482a3b636 (diff) |
Replace QuickHull with Bullet's convex hull computer.
The code is based on the current version of thirdparty/vhacd and modified to use Godot's types and code style.
Additional changes:
- extended PagedAllocator to allow leaked objects
- applied patch from https://github.com/bulletphysics/bullet3/pull/3037
Diffstat (limited to 'modules/gdnavigation/navigation_mesh_generator.cpp')
-rw-r--r-- | modules/gdnavigation/navigation_mesh_generator.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/gdnavigation/navigation_mesh_generator.cpp b/modules/gdnavigation/navigation_mesh_generator.cpp index a7d4e79148..7d30ce0f44 100644 --- a/modules/gdnavigation/navigation_mesh_generator.cpp +++ b/modules/gdnavigation/navigation_mesh_generator.cpp @@ -32,7 +32,7 @@ #include "navigation_mesh_generator.h" -#include "core/math/quick_hull.h" +#include "core/math/convex_hull.h" #include "core/os/thread.h" #include "scene/3d/collision_shape_3d.h" #include "scene/3d/mesh_instance_3d.h" @@ -220,7 +220,7 @@ void NavigationMeshGenerator::_parse_geometry(Transform p_accumulated_transform, Vector<Vector3> varr = Variant(convex_polygon->get_points()); Geometry3D::MeshData md; - Error err = QuickHull::build(varr, md); + Error err = ConvexHullComputer::convex_hull(varr, md); if (err == OK) { PackedVector3Array faces; |