Film kit command
timeline.trim
Trim Edit
Trims `clip`'s in or out `edge` by `delta` ticks or `deltaFrames`: `mode` regular leaves a gap or overlaps; ripple moves later clips to keep the edit closed. `snap` ("markers", "beats" or both) lands the trimmed edge on the nearest sequence marker or music beat within `toleranceFrames` (3).
- Kit
- Film 0.1.0 (.kfilm)
- Changes the document
- yes
- Acts on
clip(one id), which a run step’sonfills
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
clip | integer | no | |
delta | integer | no | ticks (254016000000 per second); one of several alternative parameters |
deltaFrames | integer | no | one of several alternative parameters |
edge | "in" | "out" | no | |
mode | "regular" | "ripple" | no | |
snap | any | no | "markers"|"beats"|["markers","beats"]? |
toleranceFrames | integer | no |
Call through film_run
film_run {
"path": "<file>.kfilm",
"steps": [{ "command": "timeline.trim" }]
}The required parameters, with placeholders for their types: not a tested example. Optional: clip, delta, deltaFrames, edge, mode, snap, toleranceFrames. film_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": {
"clip": {
"type": "integer",
"x-khp-types": [
"Clip"
]
},
"delta": {
"description": "ticks (254016000000 per second); one of several alternative parameters",
"type": "integer"
},
"deltaFrames": {
"description": "one of several alternative parameters",
"type": "integer"
},
"edge": {
"enum": [
"in",
"out"
],
"type": "string"
},
"mode": {
"enum": [
"regular",
"ripple"
],
"type": "string"
},
"snap": {
"description": "\"markers\"|\"beats\"|[\"markers\",\"beats\"]?"
},
"toleranceFrames": {
"default": 3,
"type": "integer"
}
},
"type": "object"
}Generated from the command list of @kition/[email protected] and the kit itself (film_commands through @kition/[email protected], built from KitionAI/kition-film@375db59). As data: commands.jsonl.