Instead of manual mappings, you can use "Families" to downgrade entire sets of schemas to a specific release label.
Core Families:
In C++, use otio::CORE_VERSION_MAP to access pre-defined maps for library releases (e.g., "0.15.0").
Custom Families (Python):
In Python, you can define custom families in a .plugin_manifest.json file located at the path specified by the OTIO_PLUGIN_MANIFEST_PATH environment variable. This allows studios to organize version sets for their own plugins (e.g., a family named "MYFAMILY" with labels like "June2022").
Use otio.versioning.fetch_map(family, label) to retrieve these maps.
# Fetch a built-in core family version
downgrade_manifest = otio.versioning.fetch_map("OTIO_CORE", "0.15.0")
otio.adapters.write_to_file(
sc,
"/path/to/file.otio",
target_schema_versions=downgrade_manifest
)
# Fetch a custom family from a plugin manifest
downgrade_manifest = otio.versioning.fetch_map("MYFAMILY", "June2022")
otio.adapters.write_to_file(
sc,
"/path/to/file.otio",
target_schema_versions=downgrade_manifest
)