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

Enabling proxy draw overrides for VP2. #191

Merged

Conversation

sirpalee
Copy link
Contributor

@sirpalee sirpalee commented Apr 3, 2017

Description of Change(s)

This PR enables Maya VP2 rendering of proxy shapes.

Fixes Issue(s)

Proxy shapes were not visible in VP2 because of the missing supportedDrawAPIs.

@mattyjams
Copy link
Contributor

Hi @sirpalee,

Thanks for the PR. We actually have this exact same change stashed away internally. We've been holding off on committing it so far though because even though we need it to make the proxies draw, we're then seeing some incorrect/inconsistent picking behavior in the viewport when we use VP2.0.

We've been talking with Autodesk about the issue and it sounds like they've added some new API on MPxDrawOverride (wantUserSelection() and userSelect() callbacks, I believe) that we can use to properly support selection when rendering in VP2.0. They added that very recently though, and at the moment it's only available in pre-release versions of Maya 2017 (starting with PR76, I'm told). I've heard that it will be included as part of 2017 Update 4 when that is released. We don't have any of these versions deployed at the moment, so we're not currently able to give it a try.

We made a note about VP2.0-related issues on the Maya USD Plugin page and included a Maya environment variable we're using to work around the problem for now. We're primarily on Maya 2016 still and have really only just started testing with 2017, so I'm not certain of the state of things with 2017. The environment variable described there has been working for us with 2016 though.

Are you seeing these issues with viewport picking when you build with this change?

@sirpalee
Copy link
Contributor Author

sirpalee commented Apr 7, 2017

Hey! We are using OpenGL - Core Profile (Compabitility) mode for 2016 ext 2 sp2 on CentOS 7. Selection seems to work fine. Is there anything to test that's known for failing?

I understand these concerns, and the confusion caused by having selection issue, but sometimes enabling the display, even with the selection issues, is a better approach. Maybe we could add an env variable to enable draw overrides?

@mattyjams
Copy link
Contributor

Hmm... We have 2016 extension 2 sp2 installed here, so I've been giving that a try this afternoon. I've set my rendering engine preference to "OpenGL - Core Profile (Compatibility)", and I have a Maya scene with one pxrUsdReferenceAssembly node in it that has a nested structure such that when I switch it to "Full", it has multiple proxy nodes underneath.

When I have the viewport set to "Legacy Default Viewport", I see everything drawing correctly, and selecting proxy nodes by picking in the viewport works correctly too. However, when I have the viewport set to "Viewport 2.0", everything draws, but selection by picking in the viewport does not work, or at least does not work consistently. I can occasionally get a marquee selection to select the proxies depending on my camera location/angle, but I have so far not gotten a single selection (non-marquee) to work. Selecting nodes directly in the outliner does correctly draw them with a wireframe outline in the viewport, but actually selecting in the viewport doesn't seem to be working.

Is there anything else about your setup I might be missing? What does the structure of the Maya scene you're testing with look like?

@jtran56
Copy link

jtran56 commented Jun 2, 2017

Filed as internal issue #147133.

@pixar-oss pixar-oss merged commit a7e8bfd into PixarAnimationStudios:dev Nov 11, 2017
pixar-oss added a commit that referenced this pull request Nov 11, 2017
Enabling proxy draw overrides for VP2.
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