Open timlehr opened 3 months ago
@markreidvfx I confirmed all but one of the tests producing valid results in Avid MC. However I can't get the audio import test test_transcribe_embed_wav_audio
to produce results that MC can load. It errors out on import. Any chance you could have a look at this? Otherwise this PR is good for review now. :)
@reinecke @jminor After our discussion I reworked the code a little and it now offers both read and write hooks to facilitate embedding & extracting of media. I also added test coverage for all supported media types using snippets from Picchu.
Link the Issue(s) this Pull Request is related to.
Requires
pyaaf>=1.7.0
Requires change to OTIO core (for tests to pass): https://github.com/AcademySoftwareFoundation/OpenTimelineIO/pull/1711
Summarize your change.
This PR adds AAF adapter specific hooks that can be used to implement just-in-time transcoding of media for embedding purposes. It also adds the
embed_essence
argument to the write functionality, which will attempt to import media references. The newcreate_edgecode
argument allows to control if an edge code should be applied to the AAF. Only.wav
,.dnx
and.aaf
can be embedded. Thanks a lot @markreidvfx for your help with the embedding code.New hooks introduced:
otio_aaf_pre_write_transcribe
: useful for transcoding media for embeddingotio_aaf_post_write_transcribe
: useful for cleaning up in-memory timeline / reverting to original mediaotio_aaf_pre_read_transcribe
: useful to modify AAF structure in-memory before readotio_aaf_post_read_transcribe
: useful to extract media from AAF file post timeline transcriptionReference associated tests.
Draft PR since I'm missing a test for .aaf embedding still
tests/test_aaf_adapter.py