mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-05-08 11:38:08 +03:00
Reduced Vertex Count for Bars from 9 to 5
Added define for PI for shaders Added Primes to Vertex Hash generation Fixed Debris
This commit is contained in:
parent
e013ed4e24
commit
915b438f5a
17 changed files with 100 additions and 77 deletions
|
@ -252,7 +252,9 @@ namespace T5M::Renderer
|
|||
vertex->IndexInPoly = k;
|
||||
vertex->OriginalIndex = v;
|
||||
vertex->Effects = room->effects[v];
|
||||
vertex->hash = std::hash<float>{}(vertex->Position.x) ^ std::hash<float>{}(vertex->Position.y) ^ std::hash<float>{}(vertex->Position.z);
|
||||
unsigned long long primes[]{ 73856093ULL ,19349663ULL ,83492791ULL };
|
||||
|
||||
vertex->hash = std::hash<float>{}((vertex->Position.x)* primes[0]) ^ (std::hash<float>{}(vertex->Position.y)* primes[1]) ^ std::hash<float>{}(vertex->Position.z) * primes[2];
|
||||
vertex->Bone = 0;
|
||||
|
||||
lastVertex++;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue