mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
Merged in hotfix/maya-set-fps (pull request #339)
fixed Maya set fps Approved-by: Milan Kolar <milan@orbi.tools>
This commit is contained in:
commit
48efc6bcee
1 changed files with 5 additions and 0 deletions
|
|
@ -1774,6 +1774,11 @@ def set_scene_fps(fps, update=True):
|
|||
'48000': '48000fps'}
|
||||
|
||||
# pull from mapping
|
||||
# this should convert float string to float and int to int
|
||||
# so 25.0 is converted to 25, but 23.98 will be still float.
|
||||
decimals = int(str(fps-int(fps))[2:])
|
||||
if decimals == 0:
|
||||
fps = int(fps)
|
||||
unit = fps_mapping.get(str(fps), None)
|
||||
if unit is None:
|
||||
raise ValueError("Unsupported FPS value: `%s`" % fps)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue