1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-23 17:30:17 +01:00

More efficiency in TrackTimeUpdate

This commit is contained in:
Paul Licameli
2018-08-11 20:25:36 -04:00
parent ce1ce688ff
commit 3886113b91

View File

@@ -5497,7 +5497,11 @@ void AudioIO::PlaybackSchedule::TrackTimeUpdate(double realElapsed)
bool foundTotal = false;
do {
auto oldTime = time;
time = mTimeTrack->SolveWarpedLength(time, realElapsed);
if (foundTotal && fabs(realElapsed) > fabs(total))
// Avoid SolveWarpedLength
time = mT1;
else
time = mTimeTrack->SolveWarpedLength(time, realElapsed);
if (Looping() && Overruns( time )) {
// Bug1922: The part of the time track outside the loop should not
// influence the result