VSE: Smooth transition for retiming tool #107197

Merged
Richard Antalik merged 20 commits from iss/blender:retiming-gradual into main 2023-05-16 22:33:19 +02:00

20 Commits

Author SHA1 Message Date
Richard Antalik 9c76a5fcc0 Remove unused function 2023-05-16 22:02:06 +02:00
Richard Antalik edee24f246 Merge branch 'main' into retiming-gradual
buildbot/vexp-code-patch-coordinator Build done. Details
2023-05-16 21:44:01 +02:00
Richard Antalik 4058e5869e Cleanup 2023-05-16 21:20:51 +02:00
Richard Antalik 1f546d1b6a Change gizmo color when pressing shift
buildbot/vexp-code-patch-coordinator Build done. Details
2023-05-16 18:46:28 +02:00
Richard Antalik 2a3e0f4194 Fix green handle - this was debug aid 2023-05-16 18:03:23 +02:00
Richard Antalik 8c26feff9b Fix `operator*` function returning address
buildbot/vexp-code-patch-coordinator Build done. Details
2023-05-16 14:59:52 +02:00
Richard Antalik 64d5479924 Another set of fixes and improvements 2023-05-16 14:58:31 +02:00
Richard Antalik bce05127f4 Fix labels, handle illegal actions(can't add handle to transition segment) 2023-05-16 13:31:26 +02:00
Richard Antalik 421b23396f Fix naming - gradient -> transition 2023-05-16 13:00:36 +02:00
Richard Antalik 734a4928a0 Assign name to flag 2023-05-16 12:56:58 +02:00
Richard Antalik 5aef799ef8 Bunch of fixes 2023-05-16 12:53:12 +02:00
Richard Antalik 80f7ca7181 Fix AV sync issue caused by using incorrect function. 2023-05-15 20:58:22 +02:00
Richard Antalik df2dfe32b2 Fix technicalityy 2023-05-09 20:50:30 +02:00
Richard Antalik ff060313cc Make sound speed evaluation slightly better. Now I think it should work in theory, but in practice it still doesn't. 2023-05-02 16:33:48 +02:00
Richard Antalik ee11e688bd Implement sound retiming transition.
Unfortunately, as I thought, my arc style transition and simple linear interpolation between 2 speeds results in sound playback being very out of sync.
Will try to calculate speed based on values provided by `seq_retiming_evaluate`. This is horribly unelegant, but will try to make this feature complete before trying to optimize.
Also have to test synchronization to audio, but ut works with retiming already somehow without touching it, so I think that is OK.
2023-05-02 14:08:55 +02:00
Richard Antalik 739aae3470 Merge branch 'main' into retiming-gradual 2023-05-02 10:59:36 +02:00
Richard Antalik b08e99fb35 fix build error
buildbot/vexp-code-patch-coordinator Build done. Details
2023-04-24 17:09:33 +02:00
Richard Antalik 00d18f6f0f Fix incorrect type
buildbot/vexp-code-patch-coordinator Build done. Details
2023-04-24 16:32:11 +02:00
Richard Antalik b95f70702f Mostly some polishing and preventing undefined behavior.
buildbot/vexp-code-patch-coordinator Build done. Details
2023-04-24 02:06:51 +02:00
Richard Antalik 7ff87edc3d WIP: VSE: Gradual retiming
This feature allows to smooth transition between 2 retimed segments.

Smooth transition is achieved by evaluating Y value of arc that is
tangent to lines of linear retimed segments. Because of this, when
transition length is changed both handles are moved symetrically. This
way it is possible to make transition without affecting content in
linear segments.

TODO:
 - Modal move operation results in precision issues. Not sure why, but I assume, that this is result of new `SEQ_retiming_remove_handle()` and workflow "delete gradient, and create new one".
 - It's probably best to make `SEQ_retiming_remove_handle()` work with gradients based on geometry. Workflow mentioned above also invalidates all pointers which makes code ugly.
 - Make visual feedback, that gradient will be added on shift key.
 - Fix label to show gradient.
 - Bunch of limits are probably missing everywhere.
 - Merge with sound support.
2023-04-20 21:54:01 +02:00