17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-29 05:47:28 +01:00

perf(gpucull): keep the walks of the submodel trees of the instances from frame to frame and make them again only when the model changes (gfx.gpucull.walkcache)

This commit is contained in:
2026-10-24 01:01:43 +02:00
parent 794ac578de
commit 3e2d292709
10 changed files with 264 additions and 36 deletions

View File

@@ -824,6 +824,18 @@ void TDynamicObject::ABuLittleUpdate(double ObjSqrDist)
// NBMX wrzesien, MC listopad: zuniwersalnione
btnOn = false; // czy przywrócić stan domyślny po renderowaniu
// the submodels set below are shared with whatever else is drawn with the same models
for( auto *model : { mdModel, mdLoad, mdLowPolyInt, mdKabina } ) {
if( model != nullptr ) {
model->state_changed();
}
}
for( auto *model : mdAttachments ) {
if( model != nullptr ) {
model->state_changed();
}
}
if (mdLoad) // tymczasowo ładunek na poziom podłogi
if (vFloor.z > 0.0)
mdLoad->GetSMRoot()->SetTranslate(modelShake + vFloor);