timeruler: reworked and improved cache status

This commit is contained in:
itsmattkc
2020-05-15 16:15:24 +10:00
parent a40eaa1ed5
commit 7c2280944b
9 changed files with 54 additions and 45 deletions
+5 -2
View File
@@ -89,10 +89,13 @@ void ViewerOutput::InvalidateCache(const TimeRange &range, NodeInput *from, Node
if (from == texture_input_ || from == samples_input_) {
emit GraphChangedFrom(source);
TimeRange invalidated_range(qMax(rational(), range.in()),
qMin(GetLength(), range.out()));
if (from == texture_input_) {
video_frame_cache_.Invalidate(range);
video_frame_cache_.Invalidate(invalidated_range);
} else {
audio_playback_cache_.Invalidate(range);
audio_playback_cache_.Invalidate(invalidated_range);
}
}