Scene kit command

compositor.setImage

Set Compositing Image

Sets the image an image node of the compositing group reads (workspace path or base64).

Kit
Scene 0.1.0 (.kscene)
Changes the document
yes

Parameters

Parameters of compositor.setImage
NameTypeRequiredDescription
base64stringnoThe image file's bytes, base64
clearbooleannoTake the node's picture away
groupinteger | stringnoThe compositing group (the one renders use when left out): its id or name
imagestringnoAn image the scene has already, by its hash
namestringnoThe image's name, with base64
nodeintegeryesThe Image node's id
pathstringnoAn image file (PNG, JPEG, or Radiance HDR) to read

Call through scene_run

text
scene_run {
  "path": "<file>.kscene",
  "steps": [{ "command": "compositor.setImage", "params": { "node": <integer> } }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: base64, clear, group, image, name, path. scene_run answers the step’s result in completed[i].result.

Result

The kit gives no result schema for this command.

Parameter schema

json
{
  "additionalProperties": false,
  "properties": {
    "base64": {
      "description": "The image file's bytes, base64",
      "type": "string"
    },
    "clear": {
      "description": "Take the node's picture away",
      "type": "boolean"
    },
    "group": {
      "description": "The compositing group (the one renders use when left out): its id or name",
      "oneOf": [
        {
          "type": "integer"
        },
        {
          "type": "string"
        }
      ],
      "x-khp-name": "name",
      "x-khp-types": [
        "NodeGroup"
      ]
    },
    "image": {
      "description": "An image the scene has already, by its hash",
      "type": "string"
    },
    "name": {
      "description": "The image's name, with base64",
      "type": "string"
    },
    "node": {
      "description": "The Image node's id",
      "type": "integer",
      "x-khp-types": [
        "Node"
      ]
    },
    "path": {
      "description": "An image file (PNG, JPEG, or Radiance HDR) to read",
      "type": "string",
      "x-khp-file": {
        "accept": [
          "png",
          "jpg",
          "jpeg"
        ],
        "access": "read"
      }
    }
  },
  "required": [
    "node"
  ],
  "type": "object"
}

Generated from the command list of @kition/[email protected] and the kit itself (scene_commands through @kition/[email protected], built from KitionAI/kition-scene@4d06faf). As data: commands.jsonl.