Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/intern/sequencer.c
| Show First 20 Lines • Show All 3,658 Lines • ▼ Show 20 Lines | |||||
| { | { | ||||
| ImBuf *meta_ibuf = NULL, *ibuf = NULL; | ImBuf *meta_ibuf = NULL, *ibuf = NULL; | ||||
| ListBase *seqbase = NULL; | ListBase *seqbase = NULL; | ||||
| int offset; | int offset; | ||||
| seqbase = BKE_sequence_seqbase_get(seq, &offset); | seqbase = BKE_sequence_seqbase_get(seq, &offset); | ||||
| if (seqbase && !BLI_listbase_is_empty(seqbase)) { | if (seqbase && !BLI_listbase_is_empty(seqbase)) { | ||||
| if (seq->flag & SEQ_SCENE_STRIPS) { | |||||
| AnimData *adt = BKE_animdata_from_id(&seq->scene->id); | |||||
brecht: This function is used for metastrips, in which case `seq->scene` would be `NULL` and this code… | |||||
| BKE_animsys_evaluate_animdata( | |||||
ISSAuthorUnsubmitted Done Inline ActionsMaybe I should use BKE_animsys_evaluate_all_animation here? Not sure if there is maybe even some newer way, that is more preferable. ISS: Maybe I should use `BKE_animsys_evaluate_all_animation` here?
Not sure if there is maybe even… | |||||
brechtUnsubmitted Done Inline ActionsI guess BKE_animsys_evaluate_all_animation would be more correct, as the scene strips may be using animated datablocks. I'm not sure if there's a better way for this currently. Ideally the sequencer and compositor would better integrate into the dependency graph, but manually updating animation is how it works for now. brecht: I guess `BKE_animsys_evaluate_all_animation` would be more correct, as the scene strips may be… | |||||
| context->depsgraph, &seq->scene, &seq->scene->id, adt, nr + offset, ADT_RECALC_ALL); | |||||
| } | |||||
| meta_ibuf = seq_render_strip_stack(context, | meta_ibuf = seq_render_strip_stack(context, | ||||
| state, | state, | ||||
| seqbase, | seqbase, | ||||
| /* scene strips don't have their start taken into account */ | /* scene strips don't have their start taken into account */ | ||||
| nr + offset, | nr + offset, | ||||
| 0); | 0); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 52 Lines • ▼ Show 20 Lines | case SEQ_TYPE_SCENE: { | ||||
| /* step back in the list */ | /* step back in the list */ | ||||
| state->scene_parents = state->scene_parents->next; | state->scene_parents = state->scene_parents->next; | ||||
| } | } | ||||
| } | } | ||||
| else { | else { | ||||
| /* scene can be NULL after deletions */ | /* scene can be NULL after deletions */ | ||||
| ibuf = seq_render_scene_strip(context, seq, nr, cfra); | ibuf = seq_render_scene_strip(context, seq, nr, cfra); | ||||
| } | |||||
| /* Scene strips update all animation, so we need to restore original state.*/ | /* Scene strips update all animation, so we need to restore original state.*/ | ||||
| BKE_animsys_evaluate_all_animation( | BKE_animsys_evaluate_all_animation(context->bmain, context->depsgraph, context->scene, cfra); | ||||
| context->bmain, context->depsgraph, context->scene, cfra); | |||||
| } | |||||
| break; | break; | ||||
| } | } | ||||
| case SEQ_TYPE_SPEED: { | case SEQ_TYPE_SPEED: { | ||||
| ImBuf *child_ibuf = NULL; | ImBuf *child_ibuf = NULL; | ||||
| float f_cfra; | float f_cfra; | ||||
| SpeedControlVars *s = (SpeedControlVars *)seq->effectdata; | SpeedControlVars *s = (SpeedControlVars *)seq->effectdata; | ||||
| ▲ Show 20 Lines • Show All 2,268 Lines • Show Last 20 Lines | |||||
This function is used for metastrips, in which case seq->scene would be NULL and this code shouldn't run?