1
0
Fork 0
mirror of https://github.com/k4zmu2a/SpaceCadetPinball.git synced 2025-09-05 16:00:15 +02:00

Minor performance optimizations (#89)

* Optimize performance by calling FreePlayedBlocks rarely

Don't call it at every main loop iteration, only after someTime.

* Optimize more aggressively in Release mode
This commit is contained in:
Gábor Dobra 2021-11-13 12:36:22 +01:00 committed by GitHub
parent ab7184ef86
commit 585a2f7113
Signed by: GitHub
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 23 additions and 10 deletions

View file

@ -114,10 +114,10 @@ void Sound::Enable(int channelFrom, int channelTo, int enableFlag)
}
}
void Sound::Idle()
void Sound::Idle(bool performCleanup)
{
if (pMem)
WaveMix::Pump();
WaveMix::Pump(performCleanup);
}
void Sound::Activate()