AI Textures a 3D Village: Open Source, 128 Views, $4.44—and the Stalls Became Wallpaper
An open-source project lets image models directly paint textures onto a 3D blockout. 128 views, 26 minutes, $4.44, covering an entire village. But don’t let AI draw “stalls”—it will paint them as wallpaper.
An open-source project called trompe lets image models directly texture a 3D blockout. The project developer used Opus 5.5 to build the village blockout in Blender, then used FLUX 3 Klein and Fibo 2 to add textures across the entire map.
The workflow is: select 128 views around the map, have the image model paint textures for the gray areas in the frame, then project the generated images back onto the 3D model. The entire workflow is open source, with code at GitHub.

Above is the project header image, comparing the blockout with the textured result. The 128 views were run on fal, costing $4.44 and taking 26 minutes. The video below shows the process from blockout to texture.
However, having AI paint textures comes with an interesting pitfall. Someone in the comments tried asking the model to generate “market stalls,” and it painted the stalls directly onto the wall. It looks like there are stalls, but it’s actually wallpaper. The author later changed the prompt to describe only materials and used the material names from the blockout to tell the model what each gray shape represented.
This lesson is more worth recording than the final result: for objects that players need to walk up to and look around, the geometry still has to be built first. Image models are good at painting materials, but not at generating geometry out of thin air. If you want to add a stall, actually build a stall in the blockout.
The core of trompe is camera planning. It first samples points at the ground height where players can stand, excludes points floating in the air, and then filters out the actual playable area based on traversable paths. Next, from each point it renders low-resolution probes in 8 directions and greedily selects views until most visible surfaces are covered. Rooftops have separate drone views, and there is an additional ring of cameras on the outside to fill gaps.
The overall painting order is deliberate: first the player views, then rooftops, and finally the perimeter. When painting each view, already-painted textures are composited into the gray render so the image model knows which areas have already been painted and avoids duplication. The painted results are projected back onto the model through UV space, and whether to overwrite existing textures is determined by the angle and distance between the view and the surface.

By default, the project paints under overcast lighting so the output is close to albedo (base color). After the engine receives this texture, it relights it with real light sources and shadows. If outdoor mode is selected, sun shadows are baked into the texture, which looks more realistic but means shadows can no longer be adjusted dynamically.
The project is called trompe and is Apache-2.0 licensed. It supports importing your own .glb files, which need UV coordinates and a Y-up orientation. The browser handles camera planning, projection, and baking, while the image models run on fal. To run it locally, just npm install, set FAL_KEY, and npm run dev. The repository includes three example scenes: Village, Courtyard, and Hall.
The README also lists some known limitations: exterior walls in narrow gaps may remain gray; eaves may have projection misalignment; view resolution is currently 1024, and 2048 gives better detail but pushes browser memory usage to around 8GB; for now only fal is supported, not local models.
If you want AI to help texture a scene, you can try it from the GitHub repository. Make the prompt clearly describe materials, not object names. Otherwise, the AI will give you a wall of stalls.
发布时间: 2026-10-27 01:40