forked from rosebudai/OpenRCT2-Web
FAL.ai sometimes paints dark horizontal bands across sprites (from grid lines bleeding into content). The new cleanup_black_artifacts() step detects opaque pixels significantly darker than the sprite's median brightness (where the original was NOT dark) and fills them from the nearest bright neighbor. This took the Gemini visual quality rating from 2/10 to 10/10 on test sprites — no more black/dark bands, clean transparency, shape perfectly preserved. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>