Skip to content

The seven Command kinds ​

Behavior and constraints ​

This vocabulary belongs to command_list@1 and executes in array order. Full structure retains each type's conditional required/forbidden rules. The generic command object's optional fields cannot all be used with every type.

typeProgram and behavior
fullscreenRequired graphics Program; draws to named targets
presentRequired graphics Program; draws to the default framebuffer rather than arbitrary MRT
computeRequired compute Program; dispatch.groups is a three-dimensional workgroup count, with declared barriers
engineDrawTrusted provider/id/version invocation; Program is optional, with further Scene provider/category constraints
copyNo Program; source/destination, aspects, filter and restore define framebuffer transfer
clearNo Program; clears named targets or a supported default framebuffer with format-compatible values
historyCommitNo Program; resource must be history; marks frame completion without inventing a read/write access

Copy v1 permits one direct texture2D color or depth aspect, exact matching formats and nearest depth filtering. History views, stencil and combined aspects are rejected. A history resource commits at most once per frame, must have a same-frame writer and must order every writer before commit. Missing, duplicate, later or unordered writers fail.

A Program-backed engineDraw owns its invocation Program, bindings/semantics/targets/state; the Provider retains trusted geometry submission and dynamic inputs. BuiltIn fallback is a declaration recipe and forbids pack Program, bindings, semantics and drawBuffers. Viewport source/restore/synchronizeScissor and state restoration also belong to the execution contract; failure must not leave partial GL state.

Generated v5 structure ​

Required applies to the displayed object/branch. Absence of a Schema default does not establish a runtime default. Conditional rules remain in the complete definition below; Loader validation also resolves IDs, ownership, budgets and device limits.

command · v5 ​

Field / branchPresence in this objectStructural constraints
bindingsoptional heretype="array"; items=#/$defs/binding
clearoptional here$ref="#/$defs/clear"
copyoptional here$ref="#/$defs/copy"
customBindingsoptional heretype="array"; maxItems=128; items=#/$defs/customBinding
dispatchoptional here$ref="#/$defs/dispatch"
drawBuffersoptional here$ref="#/$defs/drawBufferLayout"
programoptional here$ref="#/$defs/identifier"
provideroptional here$ref="#/$defs/provider"
resourceoptional here$ref="#/$defs/identifier"
sceneBindingsoptional heretype="array"; items=#/$defs/sceneBinding
sceneProvideroptional here$ref="#/$defs/provider"
semanticsoptional heretype="array"; items=#/$defs/semantic
stateoptional here$ref="#/$defs/state"
targetsoptional here$ref="#/$defs/targets"
typerequiredenum=["fullscreen","compute","copy","clear","present","engineDraw","historyCommit"]
viewportoptional here$ref="#/$defs/viewport"
Full structural rule: #/$defs/command
json
{
  "additionalProperties": false,
  "allOf": [
    {
      "if": {
        "properties": {
          "type": {
            "const": "fullscreen"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "required": [
          "program",
          "targets"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "compute"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "required": [
          "program",
          "dispatch"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "copy"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "required": [
          "copy"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "clear"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "required": [
          "clear"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "present"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "required": [
          "program"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "historyCommit"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "required": [
          "resource"
        ]
      }
    },
    {
      "if": {
        "not": {
          "properties": {
            "type": {
              "const": "copy"
            }
          },
          "required": [
            "type"
          ]
        }
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "copy"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "not": {
          "properties": {
            "type": {
              "const": "historyCommit"
            }
          },
          "required": [
            "type"
          ]
        }
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "resource"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "compute"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "viewport"
              ]
            },
            {
              "required": [
                "clear"
              ]
            },
            {
              "required": [
                "targets"
              ]
            },
            {
              "required": [
                "state"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "present"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "targets"
              ]
            },
            {
              "required": [
                "drawBuffers"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "copy"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "program"
              ]
            },
            {
              "required": [
                "bindings"
              ]
            },
            {
              "required": [
                "semantics"
              ]
            },
            {
              "required": [
                "sceneBindings"
              ]
            },
            {
              "required": [
                "targets"
              ]
            },
            {
              "required": [
                "drawBuffers"
              ]
            },
            {
              "required": [
                "state"
              ]
            },
            {
              "required": [
                "viewport"
              ]
            },
            {
              "required": [
                "clear"
              ]
            },
            {
              "required": [
                "dispatch"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "clear"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "drawBuffers"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "historyCommit"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "program"
              ]
            },
            {
              "required": [
                "bindings"
              ]
            },
            {
              "required": [
                "semantics"
              ]
            },
            {
              "required": [
                "sceneBindings"
              ]
            },
            {
              "required": [
                "targets"
              ]
            },
            {
              "required": [
                "drawBuffers"
              ]
            },
            {
              "required": [
                "state"
              ]
            },
            {
              "required": [
                "viewport"
              ]
            },
            {
              "required": [
                "clear"
              ]
            },
            {
              "required": [
                "dispatch"
              ]
            },
            {
              "required": [
                "copy"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "const": "engineDraw"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "oneOf": [
          {
            "required": [
              "provider"
            ]
          },
          {
            "required": [
              "sceneProvider"
            ]
          }
        ]
      }
    },
    {
      "if": {
        "not": {
          "properties": {
            "type": {
              "const": "engineDraw"
            }
          },
          "required": [
            "type"
          ]
        }
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "provider"
              ]
            },
            {
              "required": [
                "sceneProvider"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "properties": {
          "type": {
            "enum": [
              "copy",
              "clear",
              "historyCommit"
            ]
          }
        }
      },
      "then": {
        "not": {
          "anyOf": [
            {
              "required": [
                "customBindings"
              ]
            }
          ]
        }
      }
    },
    {
      "if": {
        "allOf": [
          {
            "required": [
              "customBindings"
            ]
          }
        ],
        "properties": {
          "type": {
            "const": "engineDraw"
          }
        },
        "required": [
          "type"
        ]
      },
      "then": {
        "allOf": [
          {
            "not": {
              "anyOf": [
                {
                  "required": [
                    "provider"
                  ]
                }
              ]
            }
          }
        ],
        "required": [
          "program",
          "sceneProvider"
        ]
      }
    }
  ],
  "properties": {
    "bindings": {
      "items": {
        "$ref": "#/$defs/binding"
      },
      "type": "array"
    },
    "clear": {
      "$ref": "#/$defs/clear"
    },
    "copy": {
      "$ref": "#/$defs/copy"
    },
    "customBindings": {
      "items": {
        "$ref": "#/$defs/customBinding"
      },
      "maxItems": 128,
      "type": "array"
    },
    "dispatch": {
      "$ref": "#/$defs/dispatch"
    },
    "drawBuffers": {
      "$ref": "#/$defs/drawBufferLayout"
    },
    "program": {
      "$ref": "#/$defs/identifier"
    },
    "provider": {
      "$ref": "#/$defs/provider"
    },
    "resource": {
      "$ref": "#/$defs/identifier"
    },
    "sceneBindings": {
      "items": {
        "$ref": "#/$defs/sceneBinding"
      },
      "type": "array"
    },
    "sceneProvider": {
      "$ref": "#/$defs/provider"
    },
    "semantics": {
      "items": {
        "$ref": "#/$defs/semantic"
      },
      "type": "array"
    },
    "state": {
      "$ref": "#/$defs/state"
    },
    "targets": {
      "$ref": "#/$defs/targets"
    },
    "type": {
      "enum": [
        "fullscreen",
        "compute",
        "copy",
        "clear",
        "present",
        "engineDraw",
        "historyCommit"
      ]
    },
    "viewport": {
      "$ref": "#/$defs/viewport"
    }
  },
  "required": [
    "type"
  ],
  "type": "object"
}

copy · v5 ​

Field / branchPresence in this objectStructural constraints
aspectsrequiredtype="array"; minItems=1; uniqueItems=true
destinationrequiredoneOf: 2
filteroptional hereenum=["nearest","linear"]
restoreoptional hereenum=["none","frame"]
sourcerequiredoneOf: 2
Full structural rule: #/$defs/copy
json
{
  "additionalProperties": false,
  "properties": {
    "aspects": {
      "items": {
        "enum": [
          "color",
          "depth"
        ]
      },
      "minItems": 1,
      "type": "array",
      "uniqueItems": true
    },
    "destination": {
      "oneOf": [
        {
          "$ref": "#/$defs/identifier"
        },
        {
          "$ref": "#/$defs/resourceView"
        }
      ]
    },
    "filter": {
      "enum": [
        "nearest",
        "linear"
      ]
    },
    "restore": {
      "enum": [
        "none",
        "frame"
      ]
    },
    "source": {
      "oneOf": [
        {
          "$ref": "#/$defs/identifier"
        },
        {
          "$ref": "#/$defs/resourceView"
        }
      ]
    }
  },
  "required": [
    "source",
    "destination",
    "aspects"
  ],
  "type": "object"
}

clear · v5 ​

Field / branchPresence in this objectStructural constraints
coloroptional heretype="array"; minItems=4; maxItems=4
depthoptional heretype="number"; minimum=0; maximum=1
stenciloptional heretype="integer"; minimum=0
Full structural rule: #/$defs/clear
json
{
  "additionalProperties": false,
  "minProperties": 1,
  "properties": {
    "color": {
      "items": {
        "type": "number"
      },
      "maxItems": 4,
      "minItems": 4,
      "type": "array"
    },
    "depth": {
      "maximum": 1,
      "minimum": 0,
      "type": "number"
    },
    "stencil": {
      "minimum": 0,
      "type": "integer"
    }
  },
  "type": "object"
}

dispatch · v5 ​

Field / branchPresence in this objectStructural constraints
barriersoptional heretype="array"; uniqueItems=true
groupsrequiredtype="array"; minItems=3; maxItems=3
Full structural rule: #/$defs/dispatch
json
{
  "additionalProperties": false,
  "properties": {
    "barriers": {
      "items": {
        "enum": [
          "shaderImageAccess",
          "textureFetch",
          "textureUpdate",
          "shaderStorage",
          "bufferUpdate",
          "framebuffer"
        ]
      },
      "type": "array",
      "uniqueItems": true
    },
    "groups": {
      "items": {
        "minimum": 1,
        "type": "integer"
      },
      "maxItems": 3,
      "minItems": 3,
      "type": "array"
    }
  },
  "required": [
    "groups"
  ],
  "type": "object"
}

viewport · v5 ​

Field / branchPresence in this objectStructural constraints
restorerequiredenum=["none","frame"]
sourcerequiredenum=["target","frame"]
synchronizeScissoroptional heretype="boolean"
Full structural rule: #/$defs/viewport
json
{
  "additionalProperties": false,
  "properties": {
    "restore": {
      "enum": [
        "none",
        "frame"
      ]
    },
    "source": {
      "enum": [
        "target",
        "frame"
      ]
    },
    "synchronizeScissor": {
      "type": "boolean"
    }
  },
  "required": [
    "source",
    "restore"
  ],
  "type": "object"
}

provider · v5 ​

Field / branchPresence in this objectStructural constraints
idrequired$ref="#/$defs/identifier"
versionrequired$ref="#/$defs/positiveVersion"
Full structural rule: #/$defs/provider
json
{
  "additionalProperties": false,
  "properties": {
    "id": {
      "$ref": "#/$defs/identifier"
    },
    "version": {
      "$ref": "#/$defs/positiveVersion"
    }
  },
  "required": [
    "id",
    "version"
  ],
  "type": "object"
}

Complete examples ​

Sources and machine records ​

Coverage inventory · Schema v5 · Catalog v2 · Completion v2

schema-v3 · schema-v4 · schema-v5 · completion-v1 · completion-v2 · temporal · settings-guide ·

ShaderPackManifestLoader.cs

Author documentation · Manifest v5 / Scene ABI v2