usdgeom-mesh-zero-area#
Code |
VG.019 |
---|---|
Validator |
|
Compatibility |
core usd |
Tags |
🚀 |
Summary#
Faces should have non-zero area.
Faces where all vertices are co-linear or coincident waste memory and can cause rendering artifacts.
Why is it required?#
Memory inefficiency
Rendering artifacts
Physics simulation issues
Examples#
#usda 1.0
# Invalid: Zero area faces
def Mesh "MeshWithZeroAreaFaces" {
int[] faceVertexCounts = [4, 3]
int[] faceVertexIndices = [
0, 0, 1, 1, # Zero area quad (two points repeated)
2, 2, 2 # Zero area triangle (same point three times)
]
point3f[] points = [
(0,0,0),
(1,0,0),
(2,0,0)
]
}
# Valid: All faces have area
def Mesh "CleanMesh" {
int[] faceVertexCounts = [4]
int[] faceVertexIndices = [0, 1, 2, 3]
point3f[] points = [
(0,0,0),
(1,0,0),
(1,1,0),
(0,1,0)
]
}
How to comply#
Merge co-linear points
Remove zero area faces
Fix mesh generation settings