Insights

Video to Game: Turning AI Clips into Playable Three.js Worlds

This article explores an open-source workflow by Lovis Odin that converts short AI-generated video clips into playable Three.js prototypes, enabling visual comparison and interaction design.

Video to Game: Turning AI Clips into Playable Three.js Worlds

Highlights: Video as a Game Design Reference

Video to Game is an open-source agent workflow by Lovis Odin that turns short AI-generated clips into playable Three.js prototypes. The repository pairs reference videos with browser games so readers can compare the intended look and resulting interaction. Its contribution is orchestration: video analysis, asset generation, code, visual comparison, and playtesting are connected in one repeatable workflow. Repository and gallery.

https://external-v2fun-data-hk-1.oss-accelerate.aliyuncs.com/temp/2026/12/01/poster_1796094323981.gif

The author reports 31 games and approximately $202 in asset-generation spending. That figure is a project report, not an audited total covering language-model inference, development time, hosting, and every retry. We inspected the implementation rather than rerunning the complete batch. Project report.

How It Works: Analyze, Build, and Play

First, study_video.py probes the clip and extracts frames at quarter-second intervals. It creates a contact sheet, estimates a color palette from sampled frames, detects scene changes, and writes structured analysis. The agent uses those observations to describe the camera, protagonist, environment, and a viable gameplay loop. This is interpretation of a visual reference, not recovery of the original scene geometry or hidden game code. Analysis script.

Next, fal_asset.py submits configurable generation jobs, uploads reference files, downloads returned assets, and records requests and outputs. The workflow can obtain concept images, cutouts, 3D objects, and sounds, then construct a Three.js game with controls, goals, progression, and restart behavior. The Skyfarer implementation loads models with GLTFLoader and uses AnimationMixer for available clips. Asset script; game source.

https://external-v2fun-data-hk-1.oss-accelerate.aliyuncs.com/temp/2026/12/01/poster(1)_1796094343011.gif

The last stage closes the loop. The agent compares selected video frames with gameplay captures, revising framing, lighting, fog, materials, and effects. A browser recording script replays keyboard scenarios, reads the window.__game testing interface, and captures actual timestamps and console errors. Encoding a recording at 60 fps does not prove the game sustained 60 fps; the script separately reports capture performance. Playtesting instructions; recorder.

Applications and Release Boundaries

The MIT-licensed repository is useful for visual game prototypes, interactive adaptations of generated clips, and studying how an agent can evaluate its own browser output. The recommended template uses a compact HTML entry point and assets, while the gallery also contains modular examples. Hosted dependencies and external assets mean that “browser-playable” should not automatically be read as an entirely offline, single-file deliverable. Source tree.

The gallery demonstrates authored results rather than a controlled success-rate benchmark across arbitrary videos. A clip with cinematic motion still needs explicit rules to become a game. The reviewed repository does not provide a formal future-work roadmap; no additional research direction is attributed to its author here.

FAQ

Could V2Fun replace the workflow's 3D asset-generation step?

Potentially: V2Fun can return GLB assets, and the game code already loads glTF models. An adapter would need to submit and poll V2Fun jobs, download outputs, and normalize scale, orientation, materials, and required animation clips. This is an untested integration proposal; the repository currently uses its own generation wrapper. V2Fun API; game source.

Does the input video contain the finished game’s mechanics?

Usually not. The agent infers a suitable interaction and implements controls, objectives, progression, and failure or restart states. The video provides visual direction, while the game remains newly authored code. Workflow.

What should be checked before using a generated game in a larger project?

Run the documented playtest loop, inspect console errors and gameplay states, and compare captures with the reference. Then review downloaded asset rights and external dependencies for the intended deployment; the repository’s MIT license does not itself license every third-party output. Playtesting; license.

Related Articles