Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Antalik <richardantalik@gmail.com>2020-12-20 05:58:38 +0300
committerRichard Antalik <richardantalik@gmail.com>2020-12-20 05:58:38 +0300
commit38b77ef8b22173835b3bc80efc218c3e05b9e37d (patch)
tree3575ab870d073a08a630d1c13b4df5548de3f9ea /source/blender/sequencer/intern/prefetch.c
parentc4ff91aab76a9987ec109a733d39ff800ccbd15b (diff)
VSE: Remove cost calculation from cache
This value was meant to be used for keeping images that are slowest to render in cache. Method of measurement was flawed, because it doesn't take UI overhead into consideration. Cache panel is to be removed because users should not have to tweak settings like this. It is not useful for development either, therefore it is removed completely.
Diffstat (limited to 'source/blender/sequencer/intern/prefetch.c')
-rw-r--r--source/blender/sequencer/intern/prefetch.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/source/blender/sequencer/intern/prefetch.c b/source/blender/sequencer/intern/prefetch.c
index 5ffb2287e1c..55df17c01f9 100644
--- a/source/blender/sequencer/intern/prefetch.c
+++ b/source/blender/sequencer/intern/prefetch.c
@@ -178,7 +178,7 @@ static bool seq_prefetch_is_cache_full(Scene *scene)
{
PrefetchJob *pfjob = seq_prefetch_job_get(scene);
- if (!seq_cache_is_full(pfjob->scene)) {
+ if (!seq_cache_is_full()) {
return false;
}
@@ -528,7 +528,7 @@ static PrefetchJob *seq_prefetch_start_ex(const SeqRenderData *context, float cf
}
/* Start or resume prefetching*/
-void seq_prefetch_start(const SeqRenderData *context, float timeline_frame, float cost)
+void seq_prefetch_start(const SeqRenderData *context, float timeline_frame)
{
Scene *scene = context->scene;
Editing *ed = scene->ed;
@@ -540,13 +540,12 @@ void seq_prefetch_start(const SeqRenderData *context, float timeline_frame, floa
bool running = seq_prefetch_job_is_running(scene);
seq_prefetch_resume(scene);
/* conditions to start:
- * prefetch enabled, prefetch not running, not scrubbing,
- * not playing and rendering-expensive footage, cache storage enabled, has strips to render,
- * not rendering, not doing modal transform - important, see D7820.
+ * prefetch enabled, prefetch not running, not scrubbing, not playing,
+ * cache storage enabled, has strips to render, not rendering, not doing modal transform -
+ * important, see D7820.
*/
- if ((ed->cache_flag & SEQ_CACHE_PREFETCH_ENABLE) && !running && !scrubbing &&
- !(playing && cost > 0.9) && ed->cache_flag & SEQ_CACHE_ALL_TYPES && has_strips &&
- !G.is_rendering && !G.moving) {
+ if ((ed->cache_flag & SEQ_CACHE_PREFETCH_ENABLE) && !running && !scrubbing && !playing &&
+ ed->cache_flag & SEQ_CACHE_ALL_TYPES && has_strips && !G.is_rendering && !G.moving) {
seq_prefetch_start_ex(context, timeline_frame);
}