gimp_bake
Bake a layer's live filters into its own pixels without merging layers, preserving layer type and mask confinement; use all:true to bake every filtered layer at once.
Instructions
Headless GIMP: bake a layer's live filters into its own pixels without merging it into anything else — the layer survives as itself, just with no more re-editable filters; a text layer stays a text layer (baking never rasterizes one). A masked filter's confinement survives the bake exactly. Defaults to the selected layer, or the topmost layer if none is selected, the same as any other gimp_layer addressing. Baking clears any masked-filter refusal (gimp_canvas, gimp_resize_image, gimp_transform_canvas) that filter would otherwise trigger — it is the sanctioned way to make a masked adjustment safe to resize, rotate, or flip around. all: true bakes every ordinary layer with a live filter at once; a group layer is always skipped, even one that carries its own filter (GIMP cannot merge filters on a group item) — reported under skipped_groups_with_filters rather than silently ignored. Targeting a group directly (layer/layer_id) is refused outright. IRREVERSIBLE in this session: there is no undo, so gimp_checkpoint or gimp_save_xcf first when in doubt.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"image": "<image>"
},
"name": "gimp_bake"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| all | No | Bake every layer on the image that has any live filter, instead of just one. A group layer is always skipped even when it carries its own filter (GIMP cannot merge filters on a group item) — any such group is reported under skipped_groups_with_filters rather than silently ignored. | |
| image | Yes | Image id, as returned by gimp_open_document. | |
| layer | No | Layer name. Defaults to the selected layer, or the topmost layer if none is selected. Ignored when layer_id or all is given. | |
| layer_id | No | Canonical layer id. Takes priority over `layer`. Ignored when `all` is given. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | ||
| baked | No | ||
| layer_id | No | ||
| baked_layers | No | ||
| skipped_groups_with_filters | No |