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:
authorSergey Sharybin <sergey.vfx@gmail.com>2014-01-18 22:16:19 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2014-01-18 22:18:36 +0400
commitf6624b84cf75aecad2899e3e43fc28fd9d2ea0d8 (patch)
treefbe86f35b6c460201a646f72389bca1248ff1e0f /source/blender/blenkernel/intern/seqcache.c
parent7142b970853f209f6c43319b7f862bcbdbea3728 (diff)
Send sequencer render context as const pointer rather than as value
No functional changes just creepy to send rather huge structure by value.
Diffstat (limited to 'source/blender/blenkernel/intern/seqcache.c')
-rw-r--r--source/blender/blenkernel/intern/seqcache.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/source/blender/blenkernel/intern/seqcache.c b/source/blender/blenkernel/intern/seqcache.c
index 38d3d46ee6b..a85e70d2afc 100644
--- a/source/blender/blenkernel/intern/seqcache.c
+++ b/source/blender/blenkernel/intern/seqcache.c
@@ -209,13 +209,13 @@ void BKE_sequencer_cache_cleanup_sequence(Sequence *seq)
IMB_moviecache_cleanup(moviecache, seqcache_key_check_seq, seq);
}
-struct ImBuf *BKE_sequencer_cache_get(SeqRenderData context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type)
+struct ImBuf *BKE_sequencer_cache_get(const SeqRenderData *context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type)
{
if (moviecache && seq) {
SeqCacheKey key;
key.seq = seq;
- key.context = context;
+ key.context = *context;
key.cfra = cfra - seq->start;
key.type = type;
@@ -225,11 +225,11 @@ struct ImBuf *BKE_sequencer_cache_get(SeqRenderData context, Sequence *seq, floa
return NULL;
}
-void BKE_sequencer_cache_put(SeqRenderData context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type, ImBuf *i)
+void BKE_sequencer_cache_put(const SeqRenderData *context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type, ImBuf *i)
{
SeqCacheKey key;
- if (i == NULL || context.skip_cache) {
+ if (i == NULL || context->skip_cache) {
return;
}
@@ -238,7 +238,7 @@ void BKE_sequencer_cache_put(SeqRenderData context, Sequence *seq, float cfra, s
}
key.seq = seq;
- key.context = context;
+ key.context = *context;
key.cfra = cfra - seq->start;
key.type = type;
@@ -271,7 +271,7 @@ static void preprocessed_cache_destruct(void)
preprocess_cache = NULL;
}
-ImBuf *BKE_sequencer_preprocessed_cache_get(SeqRenderData context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type)
+ImBuf *BKE_sequencer_preprocessed_cache_get(const SeqRenderData *context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type)
{
SeqPreprocessCacheElem *elem;
@@ -288,7 +288,7 @@ ImBuf *BKE_sequencer_preprocessed_cache_get(SeqRenderData context, Sequence *seq
if (elem->type != type)
continue;
- if (seq_cmp_render_data(&elem->context, &context) != 0)
+ if (seq_cmp_render_data(&elem->context, context) != 0)
continue;
IMB_refImBuf(elem->ibuf);
@@ -298,7 +298,7 @@ ImBuf *BKE_sequencer_preprocessed_cache_get(SeqRenderData context, Sequence *seq
return NULL;
}
-void BKE_sequencer_preprocessed_cache_put(SeqRenderData context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type, ImBuf *ibuf)
+void BKE_sequencer_preprocessed_cache_put(const SeqRenderData *context, Sequence *seq, float cfra, seq_stripelem_ibuf_t type, ImBuf *ibuf)
{
SeqPreprocessCacheElem *elem;
@@ -314,7 +314,7 @@ void BKE_sequencer_preprocessed_cache_put(SeqRenderData context, Sequence *seq,
elem->seq = seq;
elem->type = type;
- elem->context = context;
+ elem->context = *context;
elem->ibuf = ibuf;
preprocess_cache->cfra = cfra;