compare_frames
Compare two frames pixel by pixel to get changed pixel count, percentage, and bounding box. Use while animating to verify frame differences.
Instructions
Compare two frames and report how much they differ.
Flattens the sprite (non-destructively) and diffs the two frames pixel by pixel. Use while animating to confirm a frame actually changed, or that it did not change too much.
Args: filename: Aseprite file to read frame_a: First frame index, starting at 1 frame_b: Second frame index, starting at 1
Returns: JSON with changed pixel count, total pixels, percent changed, and the bounding box of the changed region.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| frame_a | Yes | ||
| frame_b | Yes | ||
| filename | Yes |