mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-01 16:34:53 +01:00
frames adjusted to mov file
This commit is contained in:
parent
9bac7aba0e
commit
e78eb840ac
1 changed files with 10 additions and 5 deletions
|
|
@ -92,8 +92,12 @@ class LoadMov(api.Loader):
|
|||
version = context['version']
|
||||
version_data = version.get("data", {})
|
||||
|
||||
first = version_data.get("startFrame", None)
|
||||
last = version_data.get("endFrame", None)
|
||||
orig_first = version_data.get("startFrame", None)
|
||||
orig_last = version_data.get("endFrame", None)
|
||||
diff = orig_first - 1
|
||||
# set first to 1
|
||||
first = orig_first - diff
|
||||
last = orig_last - diff
|
||||
handles = version_data.get("handles", None)
|
||||
handle_start = version_data.get("handleStart", None)
|
||||
handle_end = version_data.get("handleEnd", None)
|
||||
|
|
@ -103,9 +107,10 @@ class LoadMov(api.Loader):
|
|||
handle_start = handles
|
||||
handle_end = handles
|
||||
|
||||
# create handles offset
|
||||
first -= handle_start
|
||||
last += handle_end
|
||||
# create handles offset (only to last, because of mov)
|
||||
last += handle_start + handle_end
|
||||
# offset should be with handles so it match orig frame range
|
||||
offset_frame = orig_first + handle_start
|
||||
|
||||
# Fallback to asset name when namespace is None
|
||||
if namespace is None:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue