matrix_diff
Compare baseline PNGs in a directory against matching current PNGs to report changed percentage and bounding boxes for visual regression checks.
Instructions
Compare every baseline PNG in a directory with the matching current PNG and report changed percentage and bounds.
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": {
"baseline_dir": "<baseline_dir>"
},
"name": "matrix_diff"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| threshold | No | Per-pixel channel delta (default: 12) | |
| output_dir | No | Directory containing current PNGs (default: sibling 'current') | |
| baseline_dir | Yes | Directory containing baseline PNGs |