Requirements#
Warning
This feature is currently a work in progress.
What is a requirement?#
A requirement is a specific condition that must be met for an asset to be considered valid.
A requirement may contain attributes as:
A code to identify the requirement.
A message to display when the requirement is not met.
A path to a documentation page that explains the requirement.
A compatibility tag that indicates the requirement is only relevant to certain use cases.
Requirements may contain more information in the future.
What is a capability?#
A capability is a collection of requirements. It is used to group requirements that are related to a specific feature.
Where are requirements defined?#
Requirements need to conform to the contract omni.asset_validator.Requirement defined in omni.asset_validator.
As such, any class conforming to this contract can be used as a requirement.
In particular, requirements in Asset Validator are defined in the omni.capabilities module. We will use it
in the following examples.
Adding requirements to your validation rules#
To add requirements to your validation rules, you can use the register_requirement decorator. Here’s an example:
import omni.capabilities as cap
from omni.asset_validator import register_requirement, BaseRuleChecker
@register_requirement(cap.GeometryRequirements.VG_001)
class CustomRule(BaseRuleChecker):
def __init__(self):
super().__init__()
To report an issue, for example with the AddFailedCheck method, you can use the following code:
self._AddFailedCheck(
requirement=cap.GeometryRequirements.VG_001,
at=source,
)
The requirement will automatically fill in attributes such as the message, path, and compatibility tag. To override these attributes, you can set them manually, for example to change the message:
self._AddFailedCheck(
requirement=cap.GeometryRequirements.VG_001,
at=source,
message="Custom message",
)
Requirements#
AA.002#
Message |
Rule |
Link |
Asset must use only supported file types |
AA.001#
Message |
Rule |
Link |
Asset references should use anchored paths |
AA.OV.001#
Message |
Rule |
Link |
Texture UDIMs are not supported in USDZ files in NVIDIA Omniverse |
|
UN.001#
Message |
Rule |
Link |
Stage must specify upAxis to define the orientation of the stage |
UN.002#
Message |
Rule |
Link |
Stage must specify metersPerUnit to define the linear unit scale |
VG.002#
Message |
Rule |
Link |
Boundable geometry primitives should have valid extent values. |
VG.010#
Message |
Rule |
Link |
Do not subdivide meshes with Normals. |
VG.007#
Message |
Rule |
Link |
Mesh geometry must be manifold |
VG.009#
Message |
Rule |
Link |
Use indexed primvars when values are repeated |
VG.018#
Message |
Rule |
Link |
Mesh topology should be without unused vertices, edges, or faces. |
VG.019#
Message |
Rule |
Link |
Faces should have non-zero area. |
VG.016#
Message |
Rule |
Link |
Each vertex position should be unique |
VG.014#
Message |
Rule |
Link |
Mesh topology must be valid |
VG.011#
Message |
Rule |
Link |
Only include primvars that are actively used |
VG.027#
Message |
Rule |
Link |
All non-subdivided meshes must have normals. |
HI.004#
Message |
Rule |
Link |
Stage must specify a default prim to define the root entry point. |
VM.MDL.001#
Message |
Rule |
Link |
MDL material source assets must be properly referenced and accessible to ensure material loading and rendering. |
VM.BIND.001#
Message |
Rule |
Link |
Material bindings must use appropriate scope to ensure proper material assignment and inheritance. |
VM.PS.001#
Message |
Rule |
Link |
Material attributes must comply with the UsdPreviewSurface specification to ensure consistent rendering and viewer compatibility. |
VM.MDL.002#
Message |
Rule |
Link |
MDL Shaders must standard OpenUSD shader source attributes to ensure compatibility. |
|
RB.005#
Message |
Rule |
Link |
Rigid bodies cannot be part of a scene graph instance. |
RB.006#
Message |
Rule |
Link |
Rigid bodies can not be nested unless xformOp reset xform stack is used. |
RB.003#
Message |
Rule |
Link |
Rigid bodies have to be UsdGeomXformable prims. |
RB.009#
Message |
Rule |
Link |
Rigid bodies have to be UsdGeomXformable prims without skew matrix. |
RB.COL.004#
Message |
Rule |
Link |
The collision shape scale must be uniform for the following geometries: Sphere, Capsule, Cylinder, Cone & Points. |
JT.002#
Message |
Rule |
Link |
Targets set to Body0 and Body1 relationships must exist. |
JT.003#
Message |
Rule |
Link |
Body0 and Body1 relationships must not have more than one target. |
JT.ART.002#
Message |
Rule |
Link |
Articulation roots cannot be nested. |
JT.ART.003#
Message |
Rule |
Link |
Articulations are not allowed on kinematic bodies. |
JT.ART.004#
Message |
Rule |
Link |
Articulations are not allowed on static bodies. |
VG.RTX.001#
Message |
Rule |
Link |
World space bounds must not exceed RTX limit. |
|
VG.020#
Message |
Rule |
Link |
The values of points must not exceed the limit at which a given precision can be represented using 32-bit floats. |
|