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:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user