scanner_preview_to_angles
Converts a box drawn on a scan preview JPEG into horizontal and vertical instrument angles for launching an area scan, with optional margin padding on every side.
Instructions
Convert a box drawn on a scan's preview JPEG into instrument angles for
scanner_launch_area_scan. Both files must already be in the download
directory (scanner_download_scanfile + scanner_download_preview of the same
scan, taken from the station the instrument is still standing on).
(x0, y0)-(x1, y1) are preview pixel corners, y down; if x1 < x0 the box
wraps across the panorama seam. margin_deg pads every side.
Returns start_ha/delta_ha/start_va/delta_va in radians (VA from zenith).
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": {
"scan_filename": "<scan_filename>",
"preview_filename": "<preview_filename>",
"x0": "<x0>",
"y0": "<y0>",
"x1": "<x1>",
"y1": "<y1>"
},
"name": "scanner_preview_to_angles"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x0 | Yes | ||
| x1 | Yes | ||
| y0 | Yes | ||
| y1 | Yes | ||
| margin_deg | No | ||
| scan_filename | Yes | ||
| preview_filename | Yes |