#usda 1.0
(
    customLayerData = {
        dictionary cameraSettings = {
            dictionary Front = {
                double3 position = (0, 0, 50000)
                double radius = 500
            }
            dictionary Perspective = {
                double3 position = (500.0000000000001, 500.0000000000001, 499.9999999999998)
                double3 target = (0, 0, 0)
            }
            dictionary Right = {
                double3 position = (-50000, 0, -1.1102230246251565e-11)
                double radius = 500
            }
            dictionary Top = {
                double3 position = (-4.329780281177466e-12, 50000, 1.1102230246251565e-11)
                double radius = 500
            }
            string boundCamera = "/OmniverseKit_Persp"
        }
        dictionary omni_layer = {
            dictionary muteness = {
            }
        }
    }
    defaultPrim = "World"
    endTimeCode = 100
    metersPerUnit = 0.01
    startTimeCode = 0
    subLayers = [
        @./TestNodeLibrary.usda@
    ]
    timeCodesPerSecond = 24
    upAxis = "Y"
)

def Xform "World"
{
    def DistantLight "defaultLight" (
        prepend apiSchemas = ["ShapingAPI"]
    )
    {
        float angle = 1
        float intensity = 3000
        float shaping:cone:angle = 180
        float shaping:cone:softness
        float shaping:focus
        color3f shaping:focusTint
        asset shaping:ies:file
        double3 xformOp:rotateXYZ = (315, 0, 0)
        double3 xformOp:scale = (1, 1, 1)
        double3 xformOp:translate = (0, 0, 0)
        uniform token[] xformOpOrder = ["xformOp:translate", "xformOp:rotateXYZ", "xformOp:scale"]
    }

    def OmniGraph "PushGraph"
    {
        token evaluationMode = "Automatic"
        token evaluator:type = "push"
        token fabricCacheBacking = "Shared"
        int2 fileFormatVersion = (1, 4)
        token pipelineStage = "pipelineStageSimulation"

        def OmniGraphNode "madd" (
            prepend apiSchemas = ["OmniGraphCompoundNodeAPI", "NodeGraphNodeAPI"]
        )
        {
            custom token inputs:a
            prepend token inputs:a.connect = </World/PushGraph/constant_double.inputs:value>
            custom token inputs:b
            prepend token inputs:b.connect = </World/PushGraph/constant_double_01.inputs:value>
            custom token inputs:c
            prepend token inputs:c.connect = </World/PushGraph/constant_double_02.inputs:value>
            token node:type = "/World/Compounds/Madd"
            token node:type.connect = </World/Compounds/Madd>
            int node:typeVersion = 0
            rel omni:graph:compoundGraph = </World/PushGraph/madd/Graph>
            token omni:graph:compoundType = "nodetype"
            custom token outputs:sum
            prepend token outputs:sum.connect = </World/PushGraph/madd/Graph/add.outputs:sum>
            uniform token ui:nodegraph:node:expansionState = "open"
            uniform float2 ui:nodegraph:node:pos = (304, 112)

            def "Graph" (
                prepend references = @./TestNodeLibrary.usda@</World/Compounds/Madd/Graph>
            )
            {
                token evaluationMode = "Automatic"

                over "multiply"
                {
                    custom token inputs:a
                    prepend token inputs:a.connect = </World/PushGraph/madd.inputs:a>
                    custom token inputs:b
                    prepend token inputs:b.connect = </World/PushGraph/madd.inputs:b>
                }

                over "add"
                {
                    custom token inputs:b
                    prepend token inputs:b.connect = </World/PushGraph/madd.inputs:c>
                }
            }
        }

        def OmniGraphNode "constant_double" (
            prepend apiSchemas = ["NodeGraphNodeAPI"]
        )
        {
            custom double inputs:value = 1
            token node:type = "omni.graph.nodes.ConstantDouble"
            int node:typeVersion = 1
            uniform token ui:nodegraph:node:expansionState = "open"
            uniform float2 ui:nodegraph:node:pos = (21, 83)
        }

        def OmniGraphNode "constant_double_01" (
            prepend apiSchemas = ["NodeGraphNodeAPI"]
        )
        {
            custom double inputs:value = 2
            token node:type = "omni.graph.nodes.ConstantDouble"
            int node:typeVersion = 1
            uniform token ui:nodegraph:node:expansionState = "open"
            uniform float2 ui:nodegraph:node:pos = (19, 182)
        }

        def OmniGraphNode "constant_double_02" (
            prepend apiSchemas = ["NodeGraphNodeAPI"]
        )
        {
            custom double inputs:value = 3
            token node:type = "omni.graph.nodes.ConstantDouble"
            int node:typeVersion = 1
            uniform token ui:nodegraph:node:expansionState = "open"
            uniform float2 ui:nodegraph:node:pos = (15, 281)
        }

        def OmniGraphNode "magnitude" (
            prepend apiSchemas = ["NodeGraphNodeAPI"]
        )
        {
            custom token inputs:input
            prepend token inputs:input.connect = </World/PushGraph/madd.outputs:sum>
            token node:type = "omni.graph.nodes.Magnitude"
            int node:typeVersion = 1
            custom token outputs:magnitude
            uniform token ui:nodegraph:node:expansionState = "open"
            uniform float2 ui:nodegraph:node:pos = (541, 123)
        }
    }
}
