Skip to content

Commit 3b15602

Browse files
committed
simplify: Fix hashBuckets naming conflicts
Not clear what the best solution for this is for now - I'd like to make sure an amalgamated build works, both indexgenerator and simplifier need a hash table but it's slightly different... Might pull it out to the header at some point, or just rework to keep these completely separate.
1 parent 673f7d3 commit 3b15602

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/simplifier.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ static size_t hash(unsigned long long key)
2323
return size_t(key);
2424
}
2525

26-
static size_t hashBuckets(size_t count)
26+
// TODO: figure out naming conflicts between indexgenerator.cpp and this file
27+
static size_t hashBuckets2(size_t count)
2728
{
2829
size_t buckets = 1;
2930
while (buckets < count)
@@ -221,7 +222,7 @@ static size_t simplifyEdgeCollapse(unsigned int* result, const unsigned int* ind
221222
}
222223

223224
// edge quadrics for boundary edges
224-
meshopt_Buffer<unsigned long long> edges(hashBuckets(index_count));
225+
meshopt_Buffer<unsigned long long> edges(hashBuckets2(index_count));
225226
memset(edges.data, 0, edges.size * sizeof(unsigned long long));
226227

227228
for (size_t i = 0; i < index_count; i += 3)

0 commit comments

Comments
 (0)