Skip to content

Commit

Permalink
Merge branch 'develop' into bugfix/AY-6259_14_flame-vertical-alignmen…
Browse files Browse the repository at this point in the history
…t-not-identifying-hierotracks
  • Loading branch information
jakubjezek001 authored Nov 12, 2024
2 parents 6c060de + 58e2d02 commit 275fed8
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 8 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/upload_to_ynput_cloud.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: 📤 Upload to Ynput Cloud

on:
workflow_dispatch:
release:
types: [published]

jobs:
call-upload-to-ynput-cloud:
uses: ynput/ops-repo-automation/.github/workflows/upload_to_ynput_cloud.yml@main
secrets:
CI_EMAIL: ${{ secrets.CI_EMAIL }}
CI_USER: ${{ secrets.CI_USER }}
YNPUT_BOT_TOKEN: ${{ secrets.YNPUT_BOT_TOKEN }}
YNPUT_CLOUD_URL: ${{ secrets.YNPUT_CLOUD_URL }}
YNPUT_CLOUD_TOKEN: ${{ secrets.YNPUT_CLOUD_TOKEN }}
18 changes: 10 additions & 8 deletions client/ayon_flame/otio/flame_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,8 +218,8 @@ def create_otio_reference(clip_data, media_info, fps=None):
duration = int(clip_data["source_duration"])

# get file info for path and start frame
frame_start = 0
fps = fps or CTX.get_fps()
media_start = media_info.start_frame or 0
fps = fps or media_info.fps or CTX.get_fps()

path = clip_data["fpath"]

Expand All @@ -234,7 +234,7 @@ def create_otio_reference(clip_data, media_info, fps=None):
is_sequence = frame_number = utils.get_frame_from_filename(file_name)
if is_sequence:
file_head = file_name.split(frame_number)[0]
frame_start = int(frame_number)
start_frame = int(frame_number)
padding = len(frame_number)

metadata.update({
Expand All @@ -250,11 +250,11 @@ def create_otio_reference(clip_data, media_info, fps=None):
target_url_base=dirname + os.sep,
name_prefix=file_head,
name_suffix=extension,
start_frame=frame_start,
start_frame=start_frame,
frame_zero_padding=padding,
rate=fps,
available_range=create_otio_time_range(
frame_start,
media_start,
duration,
fps
)
Expand All @@ -270,7 +270,7 @@ def create_otio_reference(clip_data, media_info, fps=None):
otio_ex_ref_item = otio.schema.ExternalReference(
target_url=reformated_path,
available_range=create_otio_time_range(
frame_start,
media_start,
duration,
fps
)
Expand Down Expand Up @@ -356,9 +356,11 @@ def create_otio_clip(clip_data):
# create media reference
media_reference = create_otio_reference(clip_data, media_info, media_fps)

# creatae source range
# create source range
available_media_start = media_reference.available_range.start_time
conformed_media_start = available_media_start.value_rescaled_to(CTX.get_fps())
source_range = create_otio_time_range(
source_in,
conformed_media_start + source_in,
_clip_record_duration,
CTX.get_fps()
)
Expand Down

0 comments on commit 275fed8

Please sign in to comment.