RPA.Images
Crop an existing image.
Arguments
Argument | Type | Default value | Description |
---|---|---|---|
image | null | Image to crop | |
region | null | Region to crop image to | |
filename | None | Save cropped image to filename |
param image: | Image to crop |
---|---|
param region: | Region to crop image to |
param filename: | Save cropped image to filename |
Attempt to find the template from the given image.
Arguments
Argument | Type | Default value | Description |
---|---|---|---|
image | null | Path to image or Image instance, used to search from | |
template | null | Path to image or Image instance, used to search with | |
region | None | Area to search from. Can speed up search significantly. | |
limit | None | Limit returned results to maximum of limit. | |
tolerance | None | Tolerance for matching, value between 0.1 and 1.0 |
param image: | Path to image or Image instance, used to search from |
---|---|
param template: | Path to image or Image instance, used to search with |
param limit: | Limit returned results to maximum of limit. |
param region: | Area to search from. Can speed up search significantly. |
param tolerance: | |
Tolerance for matching, value between 0.1 and 1.0 | |
return: | List of matching regions |
raises ImageNotFoundError: | |
No match was found | |
raises ValueError: | |
Template is larger than search region |
Get the RGB value of a pixel in the image.
Arguments
Argument | Type | Default value | Description |
---|---|---|---|
image | null | image to get pixel from | |
point | null | coordinates for pixel or Point object |
param image: | image to get pixel from |
---|---|
param point: | coordinates for pixel or Point object |
return: | RGB value of pixel in image |
Draw a rectangle onto the image around the given region.
Arguments
Argument | Type | Default value | Description |
---|---|---|---|
image | null | image to draw onto | |
region | null | coordinates for region or Region object | |
color | red | color of rectangle | |
width | 5 | line width of rectangle |
param image: | image to draw onto |
---|---|
param region: | coordinates for region or Region object |
param color: | color of rectangle |
param width: | line width of rectangle |
return: | Image of the selected region |