Page MenuHome

Fix T91972: Meta changes length when adding strip
ClosedPublic

Authored by Richard Antalik (ISS) on Oct 6 2021, 2:38 AM.

Details

Summary

Fix T91972: Meta changes length when adding strip

SequencesMeta.new_movie() API function caused meta strip to change
length. Similar issue has been fixed in transform code by checking
if MetaStack exists. MetaStack is not used when changing data in
python.

Provide seqbase to SEQ_time_update_sequence() so the function can
check if change happens inside of meta strip.

This patch also merges seq_time_update_sequence_bounds() into
SEQ_time_update_sequence(). This is because same issue applies for
both functions and it is confusing to have more time update
functions.re if this will lead anywhere.

Diff Detail

Repository
rB Blender
Branch
T91972 (branched from master)
Build Status
Buildable 17589
Build 17589: arc lint + arc unit

Event Timeline

Richard Antalik (ISS) requested review of this revision.Oct 6 2021, 2:38 AM
Richard Antalik (ISS) created this revision.
  • Fix merge of seq_time_update_sequence_bounds into SEQ_time_update_sequence
Richard Antalik (ISS) retitled this revision from Fix T91972 to Fix T91972: Meta changes length when adding strip.Oct 6 2021, 3:01 AM
Richard Antalik (ISS) edited the summary of this revision. (Show Details)

Seems fine.

Although, we need to look into having a generator approach for iterating all sequences (avoiding extra iteration, extra memory and CPU ticks stress and so on).

P.S. On a completely unrelated topic, i think you can optimize SEQ_collection_append_strip() a bit by using BLI_gset_ensure_p_ex() (which should give you lookup+add semantic you're looking for there).

This revision is now accepted and ready to land.Oct 6 2021, 9:38 AM

Seems fine.

Although, we need to look into having a generator approach for iterating all sequences (avoiding extra iteration, extra memory and CPU ticks stress and so on).

Hmm I guess I could have used SEQ_for_each_callback with customdata for this, but level of "indirection" and setup puts me bit off. Will check other thing you suggested too.