-
Notifications
You must be signed in to change notification settings - Fork 49
change fps mapping in maya #475
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
change fps mapping in maya #475
Conversation
this change is correcting mapping fps values set like decimals. For example fps set as 25.0 wouldn't be mapped correctly. This change will cast fps to int if it finds its decimal places are zero. It is also adding more fps mapping for maya.
avalon/maya/commands.py
Outdated
| '47.952': '47.952fps', | ||
| '47.95': '47.952fps', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just wondering, should both of these values result in the same final FPS? Or is one intended to be the df (Drop Frame) variant? If the latter then it seems the resulting value is wrong?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well those are not drop frames, just way to handle rounding. I've sometime noticed that different productions specify framerates with different precision. This handle two and three decimal places as fewer or more doesn't make much sense. This could be handled in more elegant way I suppose but way one can see whats mapped to what.
BigRoy
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. I have never had to use the fractional FPS settings for productions so likely wouldn't use this, but I can see why it could be good for some.
davidlatwe
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for late respond 💦
davidlatwe
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @antirotor ! Good to be merged !
What's changed?
Fps in Maya is set by mapping actual fps number to string constants used by Maya to set time units. You can have fps set as integer - 25 or as float 25.0 They are numerically same but mapping recognize only integer. If you pull fps from system like ftrack, where this attribute is set as decimal to allow values like 23.976 it will also returns 25 as 25.0. To handle it, this change cast numbers like 25.0 to integer so mapping still works and adds few other Maya string constants.