draw_shape
Draws 2D geometric shapes—lines, rectangles, circles, and ellipses—on a specified layer using coordinates, color, and size. Use it to construct pixel art sprites and layered compositions.
Instructions
Draw a 2D geometric shape (line, rect, circle, ellipse) on a 2D layer.
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": {
"shape": "<shape>",
"x": "<x>",
"y": "<y>",
"color": "<color>"
},
"name": "draw_shape"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | Start X (line/rect) or center X (circle/ellipse). | |
| y | Yes | Start Y (line/rect) or center Y (circle/ellipse). | |
| x2 | No | End X for line/rect. | |
| y2 | No | End Y for line/rect. | |
| color | Yes | Hex color string e.g. "#38bdf8". | |
| shape | Yes | ||
| width | No | Width for rect or ellipse. | |
| filled | No | Fill interior (default: true). | |
| height | No | Height for rect or ellipse. | |
| radius | No | Radius for circle. | |
| layerIndex | No | Target 2D layer index. |