-
Notifications
You must be signed in to change notification settings - Fork 298
Add core C++ support for otioz and otiod #1869
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Glad you're diving into this!
Excited to see the otioz prototype move into the core! |
That makes sense about the adapters, I'll update the notes. If we do keep otiod I think having the read function would be a good idea. It keeps the API symmetrical and let's us update the format in the future. I also find otiod helpful for debugging, but I'm sure there are other use cases for it. Like if you had an .otio with media located in various different places, and wanted to copy it to a single high speed drive for playback. |
Kicking myself I should have proposed this earlier, it actually wasn't too difficult to write C++/Python-API code to call-down into the adapters to write otiod and otioz files, a C++ API would however simplify the call-setup-code! |
This is argument enough to keep it around in my opinion. If you want to float it at a TSC meeting and get a temperature check, I'm fine with that too. |
After some discussion in Slack:
https://academysoftwarefdn.slack.com/archives/CMQ9J4BQC/p1729878665473649
I wanted to create a proposal for adding core C++ support for otioz and otiod. I think adding them to the C++ API would have a couple of benefits:
I propose adding minizip-ng as a new dependency to support otioz. It has a permissive license (zlib), and is also used by OpenColorIO for their .ocioz files. The use of minizip-ng would be internal and not part of the OTIO public API.
Outline of the required work:
Add an enum for the media reference policy
(https://opentimelineio.readthedocs.io/en/stable/tutorials/otio-filebundles.html#mediareferencepolicy)
Add constants for the file bundle versions
Add I/O functions to SerializableObject
version
file and add it to the ZIP file.SerializableObject
and modify it based upon the media reference policy, and to change the external reference paths.to_json_string()
to createcontent.otio
and add it to the ZIP file.from_json_file()
on thecontent.otio
file in the temporary directory.Should we also add a version of this function that reads the otioz directly without unzipping it (i.e., memory-mapping)?
version
file in the directory.SerializableObject
and modify it based upon the media reference policy, and to change the external reference paths.to_json_string()
to create thecontent.otio
file in the directory.from_json_file()
on thecontent.otio
file in the otiod directory.Python bindings
Add Python bindings for the new C++ functionality and update the otioz/otiod Python adapters to use the new code.
The text was updated successfully, but these errors were encountered: