coordinate_transform
Convert scene coordinates to element-local space or element-local coordinates to scene space using a named element and to_local or to_global direction.
Instructions
Transform coordinates between local and global space relative to a named element. Use to_local to convert scene coords to element-local, to_global to convert element-local to scene coords.
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": {
"element": "<element>",
"x": "<x>",
"y": "<y>",
"direction": "<direction>"
},
"name": "coordinate_transform"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | X coordinate | |
| y | Yes | Y coordinate | |
| screen | No | Screen name to scope element search (searches all if omitted) | |
| element | Yes | Element name (h2d.Object.name) | |
| direction | Yes | Transform direction: to_local (scene→element) or to_global (element→scene) |