Diff USD Utility

About

The Diff USD Utility Extension uses python’s DiffLib to compare properties of primitives in both USDA and raw text formats. The results of the comparison are sent to the console.

To access this Extension, go to the top menu bar and click Window > Diff USD Tool. This extension is enabled by default. If it is ever disabled, it can be re-enabled from the Extension Manager by searching for omni.isaac.diff_usd.

Note

Two different primitives must be selected to generate console output. If multiple primitives are selected, the first and the last primitives are compared.

User Interface

Diff USD UI

Configuration Options

Under the Diff Type menu, you may select:

  • USDA Text Diff: This item selects the USDA text diff method and compares the output of two primitives converted to USDA.

  • Property List Diff: This item selects the raw primitive text diff method and compares the raw text of each property.

By selecting the Diff Selected Prims button, the output is sent to the console.

Tutorials & Examples

Here is an example of the output from the Diff USD Extension:

-    def Camera "CameraRight" (
+    def Camera "CameraLeft" (
         hide_in_stage_window = false
         kind = "model"
         no_delete = false
@@ -10,12 +10,11 @@

     {
         float focalLength = 24
         float focusDistance = 400
-        float fStop = 1.1
-        float horizontalApertureOffset = 0
+        float fStop = 1
         uniform token stereoRole = "right"
-        quatd xformOp:orient = (0.4999999999999995, 0.5000000000000002, 0.5000000000000003, 0.49999999999999994)
+        quatd xformOp:orient = (0.4999999999999999, 0.5000000000000001, 0.5000000000000001, 0.5000000000000001)
         double3 xformOp:scale = (1, 1, 1)
-        double3 xformOp:translate = (2.8201777361651144e-29, -172.3489951587168, -2.3665827156630385e-29)
+        double3 xformOp:translate = (0, 0, 0)
         uniform token[] xformOpOrder = ["xformOp:translate", "xformOp:orient", "xformOp:scale"]

         def Xform "OmniverseKitViewportCameraMesh" (
@@ -30,7 +29,7 @@

             bool primvars:omni:kit:isGizmo = 1
             token visibility = "invisible"
             float3 xformOp:rotateXYZ = (0, -0, 0)
-            float3 xformOp:scale = (1.0961785, 1.0961785, 1.0961785)
+            float3 xformOp:scale = (0.9729294, 0.9729294, 0.9729294)
             double3 xformOp:translate = (0, 0, 0)
             uniform token[] xformOpOrder = ["xformOp:translate", "xformOp:rotateXYZ", "xformOp:scale"]

The following example showcases an example of how to use this extension by looking for differences in two stereo cameras (one set to the wrong stereo role):