mirror of
https://github.com/godotengine/godot.git
synced 2025-12-07 22:00:10 +00:00
Remove OAHashMap, in favour of AHashMap.
The two types had (mostly) the same decisions, but `AHashMap` is a faster implementation, and is more consistent with `HashMap`.
This commit is contained in:
parent
b89c47bb85
commit
963c20565b
16 changed files with 219 additions and 878 deletions
|
|
@ -33,9 +33,9 @@
|
|||
#include "core/math/aabb.h"
|
||||
#include "core/math/projection.h"
|
||||
#include "core/math/vector3.h"
|
||||
#include "core/templates/a_hash_map.h"
|
||||
#include "core/templates/list.h"
|
||||
#include "core/templates/local_vector.h"
|
||||
#include "core/templates/oa_hash_map.h"
|
||||
#include "core/templates/vector.h"
|
||||
|
||||
#include "thirdparty/misc/r128.h"
|
||||
|
|
@ -260,7 +260,7 @@ public:
|
|||
circum_sphere_compute(points, root);
|
||||
}
|
||||
|
||||
OAHashMap<Triangle, uint32_t, TriangleHasher> triangles_inserted;
|
||||
AHashMap<Triangle, uint32_t, TriangleHasher> triangles_inserted;
|
||||
LocalVector<Triangle> triangles;
|
||||
|
||||
for (uint32_t i = 0; i < point_count; i++) {
|
||||
|
|
@ -293,7 +293,7 @@ public:
|
|||
|
||||
for (uint32_t k = 0; k < 4; k++) {
|
||||
Triangle t = Triangle(simplex->points[triangle_order[k][0]], simplex->points[triangle_order[k][1]], simplex->points[triangle_order[k][2]]);
|
||||
uint32_t *p = triangles_inserted.lookup_ptr(t);
|
||||
uint32_t *p = triangles_inserted.getptr(t);
|
||||
if (p) {
|
||||
// This Delaunay implementation uses the Bowyer-Watson algorithm.
|
||||
// The rule is that you don't reuse any triangles that were
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue