Transform layer
transform_layerTransform a layer’s pixels by moving, scaling, rotating, skewing, or flipping them around a pivot, with an option to affect only selected pixels.
Instructions
Move / scale / rotate / skew / flip a layer's pixels (or only the selected pixels with selectionOnly, which also moves the selection). Order: translate, rotate, skew, scale around origin.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "transform_layer"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| flip | No | ||
| skew | No | [skewX, skewY] degrees | |
| layer | No | Layer id, name, or index (0 = bottom, -1 = top). Default: the active layer. | |
| scale | No | uniform factor or [sx, sy] | |
| origin | No | Pivot: [x,y], "center" (canvas) or "content" (content bbox center, default) | |
| rotate | No | degrees clockwise | |
| translate | No | [dx, dy] px | |
| selectionOnly | No | Transform only selected pixels |