Vector kit command

perspective.grid.get

Perspective Grid

Answers the document's perspective grid model, its Define Grid fields and the station point.

Kit
Vector 0.1.0 (.kvector)
Changes the document
no

Parameters

Parameters of perspective.grid.get
NameTypeRequiredDescription
kindstringnoread by the command beside its listed parameters
namestringnoread by the command beside its listed parameters

Call through vector_run

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

The required parameters, with placeholders for their types: not a tested example. Optional: kind, name. vector_run answers the step’s result in completed[i].result.

Result

Result of perspective.grid.get
NameTypeRequiredDescription
defineobjectno
definedbooleanno
gridobjectno
stationobjectno
Result JSON Schema
json
{
  "additionalProperties": true,
  "properties": {
    "define": {
      "additionalProperties": true,
      "properties": {
        "angle": {
          "type": "number"
        },
        "distance": {
          "type": "number"
        },
        "gridline": {
          "type": "number"
        },
        "groundColor": {
          "type": "string"
        },
        "horizonHeight": {
          "type": "number"
        },
        "kind": {
          "type": "number"
        },
        "leftColor": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "opacity": {
          "type": "number"
        },
        "rightColor": {
          "type": "string"
        },
        "scale": {
          "items": {
            "type": "number"
          },
          "type": "array"
        },
        "thirdVp": {
          "items": {
            "type": "number"
          },
          "type": "array"
        },
        "units": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "defined": {
      "type": "boolean"
    },
    "grid": {
      "additionalProperties": true,
      "properties": {
        "angle": {
          "type": "number"
        },
        "cell": {
          "type": "number"
        },
        "distance": {
          "type": "number"
        },
        "extent": {
          "type": "number"
        },
        "groundColor": {
          "type": "string"
        },
        "height": {
          "type": "number"
        },
        "horizon": {
          "type": "number"
        },
        "kind": {
          "type": "number"
        },
        "leftColor": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "opacity": {
          "type": "number"
        },
        "origin": {
          "items": {
            "type": "number"
          },
          "type": "array"
        },
        "plane": {
          "type": "string"
        },
        "rightColor": {
          "type": "string"
        },
        "snap": {
          "type": "boolean"
        },
        "visible": {
          "type": "boolean"
        },
        "vpLeft": {
          "type": "number"
        },
        "vpRight": {
          "type": "number"
        },
        "vpVertical": {
          "items": {
            "type": "number"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "station": {
      "additionalProperties": true,
      "properties": {
        "distance": {
          "type": "number"
        },
        "x": {
          "type": "number"
        },
        "y": {
          "type": "number"
        }
      },
      "type": "object"
    }
  },
  "type": "object"
}

Parameter schema

json
{
  "additionalProperties": false,
  "properties": {
    "kind": {
      "description": "read by the command beside its listed parameters",
      "type": "string"
    },
    "name": {
      "description": "read by the command beside its listed parameters",
      "type": "string"
    }
  },
  "returns": "{grid: the model (as perspective.grid.set takes it), define: the Define Grid fields (as perspective.grid.define takes them), station: {x, y, distance} (the viewer: centre of vision on the horizon, distance to the picture plane, pt), defined: false while the document uses the default grid}",
  "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.