Motion kit command
comp.new
New Composition
Creates a composition (default 1920×1080, 29.97 fps, 10 s) and makes it active: set `name`, `width`, `height`, `frameRate`, `duration` (s), `background` and `renderer`. Returns its id; add layers to it afterwards.
- Kit
- Motion 0.1.0 (.kmotion)
- Changes the document
- yes
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
adaptiveSampleLimit | integer | no | 16–256 |
anchor | integer | no | |
background | any | no | [r,g,b]|#hex |
duration | number | no | s |
frameRate | number | no | |
height | number | no | |
motionBlurSamples | integer | no | |
name | string | no | |
open | boolean | no | |
pixelAspect | number | no | |
preserveFrameRate | boolean | no | |
preserveResolution | boolean | no | |
renderer | "classic3D" | "advanced3D" | no | |
shutterAngle | number | no | |
shutterPhase | number | no | |
startTime | number | no | (s) | startTimecode? |
startTimecode | any | no | one of several alternative parameters |
width | number | no |
Call through motion_run
motion_run {
"path": "<file>.kmotion",
"steps": [{ "command": "comp.new" }]
}The required parameters, with placeholders for their types: not a tested example. Optional: adaptiveSampleLimit, anchor, background, duration, frameRate, height, motionBlurSamples, name, open, pixelAspect, preserveFrameRate, preserveResolution, renderer, shutterAngle, shutterPhase, startTime, startTimecode, width. motion_run answers the step’s result in completed[i].result.
Result
The kit gives no result schema for this command.
Parameter schema
{
"additionalProperties": false,
"properties": {
"adaptiveSampleLimit": {
"description": "16–256",
"type": "integer"
},
"anchor": {
"type": "integer"
},
"background": {
"description": "[r,g,b]|#hex"
},
"duration": {
"description": "s",
"type": "number"
},
"frameRate": {
"type": "number"
},
"height": {
"type": "number"
},
"motionBlurSamples": {
"type": "integer"
},
"name": {
"type": "string"
},
"open": {
"type": "boolean"
},
"pixelAspect": {
"type": "number"
},
"preserveFrameRate": {
"type": "boolean"
},
"preserveResolution": {
"type": "boolean"
},
"renderer": {
"enum": [
"classic3D",
"advanced3D"
],
"type": "string"
},
"shutterAngle": {
"type": "number"
},
"shutterPhase": {
"type": "number"
},
"startTime": {
"description": "(s) | startTimecode?",
"type": "number"
},
"startTimecode": {
"description": "one of several alternative parameters"
},
"width": {
"type": "number"
}
},
"type": "object"
}Generated from the command list of @kition/[email protected] and the kit itself (motion_commands through @kition/[email protected], built from KitionAI/kition-motion@4719aa7). As data: commands.jsonl.