crop_to_selection
Crop an image canvas to the current selection bounds, or enable autocrop to detect the crop area automatically instead. Use it to trim an image to a selected region.
Instructions
Crop the image canvas to the current selection bounds.
Parameters:
autocrop: If True, auto-detect crop bounds instead of using selection (default False)
image_index: Target image index (default 0)
Returns: {status, x, y, width, height} — crop region applied
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| autocrop | No | ||
| image_index | No |