mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
Nuke: fix clip sequence loading
This commit is contained in:
parent
5efc9e0ff0
commit
84574eaca8
1 changed files with 8 additions and 5 deletions
|
|
@ -222,18 +222,21 @@ class LoadClip(plugin.NukeLoader):
|
|||
"""
|
||||
representation = deepcopy(representation)
|
||||
context = representation["context"]
|
||||
template = representation["data"]["template"]
|
||||
|
||||
# Get the frame from the context and hash it
|
||||
frame = context["frame"]
|
||||
hashed_frame = "#" * len(str(frame))
|
||||
|
||||
# Replace the frame with the hash in the originalBasename
|
||||
if (
|
||||
"{originalBasename}" in template
|
||||
and "frame" in context
|
||||
"{originalBasename}" in representation["data"]["template"]
|
||||
):
|
||||
frame = context["frame"]
|
||||
hashed_frame = "#" * len(str(frame))
|
||||
origin_basename = context["originalBasename"]
|
||||
context["originalBasename"] = origin_basename.replace(
|
||||
frame, hashed_frame
|
||||
)
|
||||
|
||||
# Replace the frame with the hash in the frame
|
||||
representation["context"]["frame"] = hashed_frame
|
||||
return representation
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue