EMSUSD-946 axis in import UI and command#3925
Merged
seando-adsk merged 1 commit intodevfrom Sep 30, 2024
Merged
Conversation
1153d34 to
ae19651
Compare
ae19651 to
47d7df5
Compare
- Add -upAxis (-upa) and -axisAndUnitMethod (-aum) flags to the base import command. - Document the new flags in the import command read-me file. - Add upAxis and axisAndUnitMethod tokens to the import job args tokens. - Add the rotateScale, addTransform and overwritePrefs tokens to the import job args token. - Add the upAxis and axisAndUnitMethod data to the UsdMayaJobImportArgs structure. - Handle parsing the new user args to build the UsdMayaJobImportArgs. - Expose the upAxis and axisAndUnitMethod data to Python. - Add the new UI related to upAxis and axisAndUnitMethod in the import UI. - Add documentation about how to add a new import or export option. Implement import rotation - Add axis conversion helper to the UsdMaya_ReadJob class. - Determine the Maya up-axis and USD up-axis. - Do nothing if they match. - Do nothing if the user requested to leave things as-is. - Otherwise either change the Maya prefs or rotate the root imported objects. - When rotating objects, group them under a group and rotate the group. - The ungroup them if the user did not want to keep the group. - Add original up axis attribute to the root nodes. - Report success or failure of axis conversion. Cleanup import code by refactoring into smaller functions to avoid code duplication. Add unit tests for all three methods.
47d7df5 to
d16663f
Compare
pierrebai-adsk
commented
Sep 23, 2024
| _DoImportPrimIt(primIt, usdRootPrim, readCtx, primReaderMap); | ||
| } | ||
| } | ||
| _ImportPrimRange(range, usdRootPrim); |
Collaborator
Author
There was a problem hiding this comment.
While in import, I refactor some code that was duplicated and moved the instance prototype cleanup to its own function for clarity.
pierrebai-adsk
commented
Sep 23, 2024
| } | ||
| } | ||
|
|
||
| bool UsdMaya_ReadJob::_CleanupPrototypes(const UsdPrim& usdRootPrim) |
Collaborator
Author
There was a problem hiding this comment.
Ignore whitespace difference will simplify the diff here. Most code is the same, just with one level less of indentation.
barbalt
approved these changes
Sep 24, 2024
Collaborator
|
Nice work, thanks for adding the readme. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implement import rotation
Cleanup import code by refactoring into smaller functions to avoid code duplication.
Add unit tests for all three methods.