convert_layer_to_background
Convert a normal layer into the sprite's opaque Background layer, filling transparent pixels deterministically with black on RGB/grayscale sprites or the transparent palette index on indexed sprites.
Instructions
Convert a normal layer into the sprite's opaque Background layer.
Its transparent pixels are filled: with black on an RGB or grayscale sprite, and with
the transparent palette index on an indexed one, which a Background shows as that
entry's colour, so no index changes and converting back restores the transparency.
The fill used to come from the editor's colour bar, so the same call gave a different
colour on every machine.
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": {
"filename": "<filename>",
"layer": "<layer>"
},
"name": "convert_layer_to_background"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| layer | Yes | ||
| filename | Yes |