Skip to content
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

Fix custom AYON OTIO export range mismatches. #38

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

robin-ynput
Copy link
Contributor

Changelog Description

resolve #31
When working with the new publisher, we found out some mismatch between OTIO native exporter ranges and custom AYON ones. This PR fixes this.

Additional info

In details the mismatches were:

  • potential embedded timecode not detected for movie and image sequence
  • Gap clip source range not starting from 0 but record range in parent
  • timeline fps override not detected
  • marker source range not remapped to clip available range
  • media source ranges not rescaled when timeline fps != source media fps

This PR focuses on making the ranges consistent between both exporters. It does not report all potential mismatch when exporting metadata, effects, names, ...

Testing notes:

  1. Export a timeline using custom AYON OTIO exporter
from ayon_resolve.api import lib
from ayon_resolve.otio import davinci_export as otio_export

otio_timeline = otio_export.create_otio_timeline(
  lib.get_current_resolve_project(),
  timeline=lib.get_current_timeline()
)
otio_export.write_to_file(otio_timeline, filepath)
  1. Export the same timeline using native OTIO exporter (Resolve >= 18.5)
from ayon_resolve.api import bmdvr, lib

timeline = lib.get_current_timeline()
timeline.Export("C:\\path\\to\\export_native.otio", bmdvr.EXPORT_OTIO)
  1. Compare the resulting files and ensure clips' source_range and available_range match

  2. My own test cases and results can be found here:

@robin-ynput robin-ynput self-assigned this Oct 16, 2024
@robin-ynput robin-ynput added type: bug Something isn't working bump minor labels Oct 16, 2024
@robin-ynput robin-ynput changed the title Adjust custom AYON OTIO export range mismatches. Fix custom AYON OTIO export range mismatches. Oct 16, 2024
@iLLiCiTiT iLLiCiTiT removed their request for review October 22, 2024 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bump minor type: bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fix clip ranges mismatches between AYON custom OTIO exporter and Resolve native OTIO exporter.
2 participants