# M00-QAR-VISUAL-DIFF-001 — Renderer checkpoint visual diff ## Ownership - Target: M00 - Program: QAR - Owner/Agent ID: sindo-main-codex - Branch: `work/sindo-main-codex/m00-checkpoint-diff` - Lease expires UTC: 2026-07-13 - Integrator: milestone integrator ## Outcome Provide a deterministic, headless perceptual comparison for paired renderer checkpoint PNGs, with machine-readable results and synthetic regression coverage. ## Non-goals - Supplying or committing original-client screenshots. - Claiming visual parity or replacing human approval. - Image registration, camera correction, or temporal animation matching. ## Paths - Exclusive: `src/tools/compare_render_checkpoints.gd` - Shared/hotspots: `src/tools/render_baseline_manifest.json`, `tools/run_render_baseline.ps1`, `docs/RENDER_BASELINE.md`, `docs/modules/world-renderer.md`, `RENDER.md` - Generated/ignored: comparison reports, diff PNGs, original-client captures ## Contracts and data - Public API/events: headless CLI arguments and JSON report documented in renderer baseline docs - Schema/format version: comparison report schema 1; baseline manifest schema remains 1 - Migration/compatibility: additive manifest budget fields - Consumers: developers and CI ## Dependencies - Requires: Godot `Image` API and M00 checkpoint naming contract - Blocks: automated portion of original-client paired comparison - External state: approved build 12340 screenshots remain unavailable ## Verification - Commands: headless self-test; manifest verification; documentation and coordination gates - Fixtures: tool-generated identical and changed 2x2 PNGs - Fidelity evidence: algorithm is deterministic; real-client evidence remains a manual/external input - Performance budget: offline checkpoint operation, linear in pixel count ## Documentation deliverables - Inline public API docs: CLI usage in script header - Module specification: update renderer verification and source map - Data-flow diagram: update baseline documentation - Sequence/state/dependency diagrams: not stateful or asynchronous; not applicable - Source map/status updates: renderer module and RENDER notes ## Simplicity and naming - Important names introduced: `mean_perceptual_error`, `changed_pixel_ratio` - Simplest considered solution: direct Godot Image iteration with no dependency - Rejected complexity/abstractions: external image library, SSIM window pipeline, image registration - Unavoidable complexity and justification: sRGB linearization avoids comparing encoded channel values directly - Measured optimization evidence: not required for offline seven-checkpoint comparison ## Status - State: ready - Done: comparator, runner integration, manifest tolerance contract, synthetic regression, module/baseline documentation, repository gates - Next: integrator review and paired run when approved build 12340 screenshots become available - Blocked by: real paired screenshots only for final human fidelity approval ## Handoff - Commit: branch HEAD - Results: synthetic identical image passed, changed image failed; full M00 dry-run and repository gates passed - Remaining risks: thresholds need calibration against approved paired captures; animation phase and camera alignment still require human review - Documentation updated: `docs/RENDER_BASELINE.md`, `docs/modules/world-renderer.md`, `RENDER.md`