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

usdview: rendering of flipped geometry looks incorrect #2536

Closed
hybridherbst opened this issue Jul 12, 2023 · 8 comments
Closed

usdview: rendering of flipped geometry looks incorrect #2536

hybridherbst opened this issue Jul 12, 2023 · 8 comments

Comments

@hybridherbst
Copy link
Contributor

hybridherbst commented Jul 12, 2023

Description of Issue

Looks like flipped geometry (e.g. scale -1,1,1) renders incorrectly in usdview. The spec says that winding order and lighting should be corrected, and some viewers (e.g. Storm in Omniverse) seem to respect this; however usdview does not.

Steps to Reproduce

  1. Download
    NegativeScaleAndAlphaScale.usdz.zip
  2. open with usdview
  3. note that the 2nd and 3rd cubes display black

image
4. switch lighting to Dome
5. note that the 2nd and 3rd cube still look wrong, looks like flipped normals?

image

Expected (Storm in Omniverse looks good):
image

Discussion in usd-wg: https://academysoftwarefdn.slack.com/archives/C02TZPYMP8S/p1689118060187999

System Information (OS, Hardware)

Both Windows 11 and MacOS 13

Build Flags

On Windows: Omniverse usdview
On Mac: build without further options from latest dev

@spitzak
Copy link

spitzak commented Jul 13, 2023

cubes.zip

This might be a useful test file(s), feel free to add them to any public repository of usd tests. Contains cubes (with the top missing) with all combinations of single/doublesided, normals or no normals, left/right handed, and inverted/normal transformation. No renderer does these all correctly. There is also a version where all the cubes are instanced, which is even worse.

@spitzak
Copy link

spitzak commented Jul 13, 2023

cubes
Possibly-correct render from Storm of the non-instanced version

@jesschimein
Copy link
Contributor

Filed as internal issue #USD-8497

@meshula
Copy link
Member

meshula commented Jul 13, 2023

These cube tests are great ~ and would make a lovely addition to https://github.com/usd-wg/assets/tree/main/test_assets !

To anyone not already on the aswf slack, there's related conversations going on here ~ https://join.slack.com/t/academysoftwarefdn/shared_invite/zt-1ygy120xu-CmzTocra0GYIxhxnGBwQOA

@spitzak
Copy link

spitzak commented Jul 13, 2023

Yes please add the tests to the free examples

@spitzak
Copy link

spitzak commented Jul 13, 2023

A shader with different front/back face colors would help as well, though I'm not sure if there is anything in UsdPreviewSurface

@spiffmon
Copy link
Member

spiffmon commented Jul 14, 2023 via email

@mnaehrig
Copy link

I'd like to point out that this is not a general problem with usdview. It depends on the platform. On Windows it also looks correct with usdview. On macOS it looks wrong. So I guess it has to do with the Metal backend. Still reproducable with OpenUSD 23.11.

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

No branches or pull requests

6 participants