mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
Eliminate per-instance hash lookups in M2 render/shadow culling loops
Use cached model flags (isValid, isSmoke, isInvisibleTrap, isGroundDetail, disableAnimation, boundRadius) on M2Instance instead of models.find() in the hot culling paths. Also complete cached flag initialization in createInstanceWithMatrix().
This commit is contained in:
parent
30fa9836d9
commit
2e432fc123
2 changed files with 38 additions and 32 deletions
|
|
@ -179,6 +179,9 @@ struct M2Instance {
|
|||
bool cachedDisableAnimation = false;
|
||||
bool cachedIsSmoke = false;
|
||||
bool cachedHasParticleEmitters = false;
|
||||
bool cachedIsGroundDetail = false;
|
||||
bool cachedIsInvisibleTrap = false;
|
||||
bool cachedIsValid = false;
|
||||
float cachedBoundRadius = 0.0f;
|
||||
|
||||
// Frame-skip optimization (update distant animations less frequently)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue