VSE: store raw images in cache

Previously raw images were not cached if image wasn't preprocessed.
This caused issue, that image had to be read from disk on every redraw.

Effect strips must be excluded, because this would cause problem with
invalidation. Effect strips can use preprocessing however. This is
mainly to allow usimg modifiers on them.

This change should follow rBf448ff2afe7a77, but I have wrongly assumed,
that it has been implemented already.

ref T80278
This commit is contained in:
Richard Antalik 2021-01-11 11:28:49 +01:00
parent 54f8a5dd73
commit 445ebcaa30
Notes: blender-bot 2023-02-14 05:41:57 +01:00
Referenced by issue #80278, VSE 2.0: Performance, Cache System
1 changed files with 5 additions and 5 deletions

View File

@ -728,12 +728,12 @@ static ImBuf *seq_render_preprocess_ibuf(const SeqRenderData *context,
use_preprocess = true;
}
if (use_preprocess) {
/* Proxies are not stored in cache. */
if (!is_proxy_image) {
seq_cache_put(context, seq, timeline_frame, SEQ_CACHE_STORE_RAW, ibuf, false);
}
/* Proxies and effect strips are not stored in cache. */
if (!is_proxy_image && (seq->type & SEQ_TYPE_EFFECT) == 0) {
seq_cache_put(context, seq, timeline_frame, SEQ_CACHE_STORE_RAW, ibuf, false);
}
if (use_preprocess) {
ibuf = input_preprocess(context, seq, timeline_frame, ibuf);
}