Skip to content

Commit

Permalink
Reverting 'clear the cache when the user seeks' experiment. It was a …
Browse files Browse the repository at this point in the history
…failed experiement, not to mention that it destroys performance on the "Transform" tool.
  • Loading branch information
jonoomph committed Jan 1, 2021
1 parent 2699e7d commit f5d6ee2
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/Timeline.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -725,15 +725,6 @@ std::shared_ptr<Frame> Timeline::GetFrame(int64_t requested_frame)
return frame;
}

// Check if previous frame was cached? (if not, assume we are seeking somewhere else on the Timeline, and need
// to clear all cache (for continuity sake). For example, jumping back to a previous spot can cause issues with audio
// data where the new jump location doesn't match up with the previously cached audio data.
std::shared_ptr<Frame> previous_frame = final_cache->GetFrame(requested_frame - 1);
if (!previous_frame) {
// Seeking to new place on timeline (destroy cache)
ClearAllCache();
}

// Minimum number of frames to process (for performance reasons)
int minimum_frames = OPEN_MP_NUM_PROCESSORS;

Expand Down

0 comments on commit f5d6ee2

Please sign in to comment.