#usda 1.0
(
    doc ="""Generated from node description file OgnGpuInteropCpuToDisk.ogn
Contains templates for node types found in that file."""
)

def OmniGraph "TestGraph"
{
    token evaluator:type = "push"
    int2 fileFormatVersion = (1, 3)
    token flatCacheBacking = "Shared"
    token pipelineStage = "pipelineStageSimulation"

    def OmniGraphNode "Template_omni_graph_examples_cpp_GpuInteropCpuToDisk" (
        docs="""Saves specified CPU buffer to disk"""
    )
    {
        token node:type = "omni.graph.examples.cpp.GpuInteropCpuToDisk"
        int node:typeVersion = 1

        # 14 attributes
        custom bool inputs:active = false (
            docs="""Alternative to frameCount/startFrame, does a single frame then autoResets to false"""
        )
        custom string inputs:aovCpu = "" (
            docs="""Name of AOV representing CPU buffer of GPU resource"""
        )
        custom string inputs:aovGpu = "" (
            docs="""Name of AOV representing GPU resource, used for querying format + properties"""
        )
        custom int inputs:autoFileNumber = -1 (
            docs="""If non zero, this number will be the starting number for export. Each invocation of this node increases the number by 1."""
        )
        custom string inputs:fileName = "" (
            docs="""Optional, if specified the output filename will be fileName_{aovGpu}.{fileType}"""
        )
        custom int inputs:fileNumber = -1 (
            docs="""Number that will be appended to the exported filename. If -1 then the render product's frame number will be used."""
        )
        custom string inputs:fileType = "png" (
            docs="""bmp,png,exr"""
        )
        custom int64 inputs:frameCount = -1 (
            docs="""Number of frames to capture (-1 means never stop)"""
        )
        custom uint64 inputs:gpu = 0 (
            docs="""Pointer to shared context containing gpu foundations"""
        )
        custom int inputs:maxInflightWrites = 2 (
            docs="""Maximum number of in-flight file write operations before blocking on file i/o"""
        )
        custom uint64 inputs:rp = 0 (
            docs="""Pointer to render product for this view"""
        )
        custom uint64 inputs:saveFlags = 0 (
            docs="""Flags that will be passed to carb::imaging::IImaging for file saving."""
        )
        custom string inputs:saveLocation = "" (
            docs="""Folder to save AOVs as AOV_FrameNumber.{exr,png}"""
        )
        custom uint64 inputs:startFrame = 0 (
            docs="""Frame to begin saving to disk"""
        )

        # 2 attributes
        custom uint64 outputs:gpu (
            docs="""Pointer to shared context containing gpu foundations"""
        )
        custom uint64 outputs:rp (
            docs="""Pointer to render product for this view"""
        )
    }
}
