clean up the codes for collect frame range and get frame range function

This commit is contained in:
Kayla Man 2023-10-20 23:25:37 +08:00
parent 69d665fd7d
commit bf38b2bbef
2 changed files with 7 additions and 5 deletions

View file

@ -254,10 +254,13 @@ def get_frame_range(asset_doc=None) -> Union[Dict[str, Any], None]:
if frame_start is None or frame_end is None:
return {}
handle_start = data.get("handleStart", 0)
handle_end = data.get("handleEnd", 0)
frame_start_handle = int(frame_start) - int(handle_start)
frame_end_handle = int(frame_end) + int(handle_end)
frame_start = int(frame_start)
frame_end = int(frame_end)
handle_start = int(data.get("handleStart", 0))
handle_end = int(data.get("handleEnd", 0))
frame_start_handle = frame_start - handle_start
frame_end_handle = frame_end + handle_end
return {
"frameStart": frame_start,
"frameEnd": frame_end,

View file

@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-
"""Collect instance members."""
import pyblish.api
from pymxs import runtime as rt