Skip to content
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

Replace callsites into deprecated "Master" API #1430

Merged
merged 2 commits into from
May 25, 2021

Conversation

dj-mcg
Copy link
Collaborator

@dj-mcg dj-mcg commented May 21, 2021

No description provided.

@@ -56,7 +56,7 @@
#include <maya/MStatus.h>
#include <maya/MTime.h>

#include <ghc/filesystem.hpp>
#include <boost/filesystem.hpp>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dj-mcg Could you clarify why you needed to make this change here? In fact, This PR should not compile at all on any platforms since we no longer support boost::filesystem.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was an oversight on my part. We change these internally since we still use boost, so this didn't show up in the diff I was looking at. I've corrected it

}
}
deleteMasterMod.doIt();
deletePrototypeMod.doIt();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found both masterObject and prototypeObject confusing. Are they not just "instance objects"? I think having a more generic name would be better.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've made the other changes as it breaks functionality, but I've left this for now since it's a style preference. If you feel strongly about changing the var names, I can raise it with the USD team. Please let me know.

@@ -179,7 +184,7 @@ UsdPrim TransformIterator::parentPrim() const
UsdPrim parentPrim = m_stage->GetPseudoRoot();
if (m_primStack.size() > 1) {
parentPrim = (m_primStack.end() - 2)->m_prim;
if (parentPrim.IsMaster()) {
if (parentPrim.IsPrototype()) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no guard against PXR_VERSION < 2011?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, thank you, this was my fault for not testing thoroughly enough before pushing. I'll make sure to start building and testing against both USD's release version and latest version prior to opening a pull request.

Copy link
Contributor

@HamedSabri-adsk HamedSabri-adsk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please see my comments.

@dj-mcg
Copy link
Collaborator Author

dj-mcg commented May 21, 2021

Oh thanks - looks like the USD folks sent me these changes, but they include some that shouldn't be pushed. Let me clean them up a bit and push again.

@dj-mcg
Copy link
Collaborator Author

dj-mcg commented May 21, 2021

Thank you for catching these, Hamed. I had assumed the author had tested these changes against the open source project but it was only tested internally. I'll make sure to more carefully review the changes that touch mayaUsd before opening a pull request.

Replace boost header with ghc
Check PXR version when using new API in the AL plugin
Copy link
Contributor

@HamedSabri-adsk HamedSabri-adsk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good. Thanks.

Regarding the variable name changes, it would be nice to clean them up but I don't think it is urgent.

It would be also nice to have a simple unit-test to back up the new changes.

@kxl-adsk kxl-adsk merged commit c8727d2 into Autodesk:dev May 25, 2021
@dj-mcg dj-mcg deleted the pr/REPLACE_DEPRECATED_MASTER_API branch May 26, 2021 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants