retrodex
Use Codex as an agent-powered pixel art editor.
A local pixel art editor built to work hand-in-hand with AI coding agents like Codex. Codex generates and edits sprites programmatically while you do the manual finishing, both working on the same files without conflicts.
Retrodex is a local pixel art editor designed to work alongside an AI coding agent called Codex. The idea is that Codex handles the generation and programmatic editing of pixel art, while you handle the manual finishing work, and both operate on the same files through the same system without stepping on each other.
The workflow goes roughly like this: you ask Codex to create a sprite, it generates an image and runs it through a cleanup pipeline before opening it for editing. The cleanup step matters because AI-generated images that look like pixel art are rarely on a clean grid at the right size. The pipeline detects the underlying pixel grid, removes backgrounds, trims leftover colors from image generation, and scores the result before handing it off. Only after cleanup passes does the image open in the browser-based editor for you to work on directly.
The browser editor is a canvas tool with the standard pixel art toolkit: brush, eraser, fill, color picker, shape tools, selections (box, lasso, magic wand), a layer mask system, and an animation timeline with frame controls. Exports cover a wide range of formats including PNG, GIF, WebP, SVG, and Lottie. Changes save automatically to a local folder.
Codex interacts with the system through a JSON command-line interface and a local API running on your machine. It can read the current pixel map of any frame, apply brush strokes at specific coordinates, manage selections, and trigger exports, all without needing to click through the browser UI. Mutations include a revision guard so that if you and Codex both make changes at roughly the same time, they do not silently overwrite each other.
The project is described as an active prototype rather than a finished product. The core image cleanup logic is written in Python, and the API, CLI, and web editor are written in TypeScript.
Where it fits
- Let an AI agent generate a game sprite, then open it in the browser editor to fix small details by hand.
- Automate bulk pixel art edits across many frames using the CLI without touching the browser UI.
- Create animated sprite sheets with frame controls and export as GIF or Lottie for use in games or apps.
- Run an image through the cleanup pipeline to snap AI-generated art onto a proper pixel grid before editing.