Skip to content

UsdGeomMesh degenerate triangles discarded #4194

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

Open
tryptik opened this issue Apr 16, 2025 · 1 comment
Open

UsdGeomMesh degenerate triangles discarded #4194

tryptik opened this issue Apr 16, 2025 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@tryptik
Copy link

tryptik commented Apr 16, 2025

Describe the bug
When importing Usd that uses meshes, Maya seems to discard degenerate triangles without warning. In addition, it fails to upadate the UV coordinates to account for the change in faces, which distorts the UV's and normals.

Steps to reproduce

  • Open Maya
  • Use "Create->Polygon Primitives->Cube"
  • From the "Modeling" menu set, use "Mesh->Triangulate" to triangulate the mesh
  • Optionally, add the cube texture file for better visualization.
  • Select the cube and export it as a .usda.
  • Using usdedit or an editor of your choice, open the exported file.
  • Select these face indices:
Image
  • Edit the indices to make the face degenerate and save the file.
Image
  • Re-import the .usda
  • Review the results.

Expected behavior
Since any number of UsdGeomPrimvars could be applied in a similar manner as UVs, it may be best to have Maya error out when such a situation is encountered, as it may be difficult for users to diagnose this issue.

Attachments
Here is the resulting cube_compare.mb file, with the good, imported and re-exported cube.

Image

Here is the resulting cube_compare.usda in UsdView:

Image

The middle cube is Usd's import of the cube with degenerate triangles, and the right cube is the re-export from Maya. Notably, Usd maintains the UV and normal mapping.

Specs (if applicable):
MacOS 15.5 M1
Maya 2025.3
Cut: 202409190603-cbdc5a7e54
mayaUsdPlugin Bundle Version: 0.30.0
For API: 20250300
Maya USD commit: 966ce2d

@tryptik tryptik added the bug Something isn't working label Apr 16, 2025
@wallworm
Copy link
Collaborator

Thanks for reporting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants