Skip to main content
WEB
Starter kitFree

trompe (texture a level from a gray blockout)

Texture a whole game level from a gray blockout with image models: trompe plans player-height cameras, has a model paint each view, projects the paintings back onto the mesh and bakes one albedo texture, exported as glTF.

GitHub stars
22
(GitHub stars as of 2026-10-26)
License
Apache-2.0
Last commit
2026/10/26
By
Patch-gg
Download ZIP

Listed from the author's README. GameSkill has not run this end to end yet. Agent support and install steps are as documented by the author.

Install

Browser app
git clone https://github.com/Patch-gg/trompe && cd trompe && npm install && FAL_KEY=your-fal-key npm run dev

Opens on http://localhost:5178. Pick a sample level or drop in your own .glb (needs UVs, Y up), describe materials, press Plan cameras, then Texture level.

Headless CLI
node scripts/texture.mjs --level samples/village.glb --id village --views 90 --atlas 8192 --style "weathered limestone and ochre plaster walls, terracotta roofs"

Saves the run to runs/<id>/. Use --resume <id> to fill gaps and --dry in scripts/prompt-test.mjs to check prompts without calling a model.

Commands are copied from the project's README. Check the repository before running anything on your machine.

What you get

  • A camera planner that samples walkable floors at eye height and picks views covering everything a player can reach
  • Per-view painting with image models under overcast light, so the bake is albedo and your engine adds real shadows
  • Projection and baking into one texture atlas, downloadable as a textured .glb or the texture alone
  • Resume, parallel and prompt A/B scripts for cheap iteration on long runs
  • Sample levels: Village, Courtyard, Hall

Good fit

  • Turning a greybox level into a consistently styled, textured level in under an hour
  • Locking one art style across a whole environment instead of texturing asset by asset
  • Prototyping the look of a 3D level before committing artist time

Not for

  • Characters or props that need clean hand-authored UVs and PBR channels
  • Fully offline pipelines: the image models run on fal

Overview

trompe takes a gray blockout and paints the whole level with image models. It plans cameras where a player could actually stand, asks a model to paint what each camera sees, projects every painting back onto the geometry and bakes a single texture. Because the paintings are lit flat, the result behaves like albedo, and your engine provides the lighting and shadows.

How it works

  1. Plan: sample walkable floors at eye height, drop spots inside solids or out of reach, connect spots a player can walk between, then greedily pick cameras until most reachable surfaces are covered.
  2. Paint: each view is painted by an image model on fal, guided by your material prompt and what has been painted so far.
  3. Project and bake: paintings are projected onto the mesh and merged into one atlas, then exported as glTF.

The author's demo village used 128 views, took 26 minutes and cost about $4.44 in model calls. The demo post on X was one of the most-shared game dev posts of the day.

Tips

  • Write the style as materials ("weathered limestone, ochre plaster, terracotta roofs").
  • Use --resume to fill holes in a finished run instead of starting over.
  • --parallel is faster but leaves seams where views meet.

License

Apache-2.0. The image models are a separate paid service.

Requirements

  • Node.js and a WebGPU/WebGL-capable GPU (planning, projection and baking run locally in the browser)
  • A fal.ai API key for the image models (paid per image; the README's village run cost about $4.44 for 128 views)
  • A blockout .glb with UVs

Topics

FAQ

Works well with

Skills the author points to as related or as the better fit for neighbouring tasks.

Similar skills