File tree Expand file tree Collapse file tree 2 files changed +33
-4
lines changed
src/py-opentimelineio/opentimelineio/console Expand file tree Collapse file tree 2 files changed +33
-4
lines changed Original file line number Diff line number Diff line change @@ -510,11 +510,13 @@ def _f(item):
510510
511511
512512def filter_effects (timelines ):
513- """Return a copy of the input timelines with all effects removed.
514- The overall duration of the timelines should not be affected, with
515- the possible exception of time warp effects, which are also removed."""
513+ """Remove all effects from the input timelines. The inputs are modified
514+ in place, and also returned."""
516515 for timeline in timelines :
517- for item in timeline .find_children ():
516+ # Items have an effects attribute, but other Composables do not.
517+ # (e.g. Transitions) so we need to find only Items.
518+ for item in timeline .find_children (descended_from_type = otio .core .Item ):
519+ # Clear the effects list contents
518520 item .effects [:] = []
519521 return timelines
520522
Original file line number Diff line number Diff line change 362362 },
363363 "active_media_reference_key": "DEFAULT_MEDIA"
364364 },
365+ {
366+ "OTIO_SCHEMA": "Transition.1",
367+ "metadata": {
368+ "Resolve_OTIO": {
369+ "Effects": {
370+ "Effect Name": "Cross Fade 0 dB",
371+ "Enabled": true,
372+ "Name": "Cross Fade",
373+ "Parameters": [],
374+ "Type": 40
375+ },
376+ "Transition Type": "Cross Fade 0DB"
377+ }
378+ },
379+ "name": "Cross Fade 0 dB",
380+ "in_offset": {
381+ "OTIO_SCHEMA": "RationalTime.1",
382+ "rate": 24.0,
383+ "value": 30.0
384+ },
385+ "out_offset": {
386+ "OTIO_SCHEMA": "RationalTime.1",
387+ "rate": 24.0,
388+ "value": 30.0
389+ },
390+ "transition_type": "SMPTE_Dissolve"
391+ },
365392 {
366393 "OTIO_SCHEMA": "Clip.2",
367394 "metadata": {
You can’t perform that action at this time.
0 commit comments