Vector kit command

perspective.grid.define

Define Perspective Grid

Defines the perspective grid as the Define Grid dialog does: preset, kind, units, scale, gridlines, viewing angle and distance, horizon and colours.

Kit
Vector 0.1.0 (.kvector)
Changes the document
yes

Parameters

Parameters of perspective.grid.define
NameTypeRequiredDescription
anglenumberno
distancenumberno
gridlinenumberno
groundColorstringnolike #rrggbb
horizonHeightnumberno
kind1 | 2 | 3no
leftColorstringno
namestringno
opacitynumberno
rightColorstringno
scaleany[]no[artboard, real world]
thirdVpnumber[]no
unitsstringno

Call through vector_run

text
vector_run {
  "path": "<file>.kvector",
  "steps": [{ "command": "perspective.grid.define" }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: angle, distance, gridline, groundColor, horizonHeight, kind, leftColor, name, opacity, rightColor, scale, thirdVp, units. vector_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": {
    "angle": {
      "type": "number"
    },
    "distance": {
      "type": "number"
    },
    "gridline": {
      "type": "number"
    },
    "groundColor": {
      "description": "like #rrggbb",
      "type": "string"
    },
    "horizonHeight": {
      "type": "number"
    },
    "kind": {
      "enum": [
        1,
        2,
        3
      ],
      "type": "integer"
    },
    "leftColor": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "opacity": {
      "type": "number"
    },
    "rightColor": {
      "type": "string"
    },
    "scale": {
      "description": "[artboard, real world]",
      "type": "array"
    },
    "thirdVp": {
      "items": {
        "type": "number"
      },
      "type": "array"
    },
    "units": {
      "type": "string"
    }
  },
  "returns": "the new define fields",
  "type": "object"
}

Generated from the command list of @kition/[email protected] and the kit itself (vector_commands through @kition/[email protected], built from KitionAI/kition-vector@7cf908f). As data: commands.jsonl.