What it is
img2threejs is a skill for Claude Code, Codex, or OpenCode that takes one reference image of an object and produces a TypeScript THREE.Group factory recreating it from primitives, procedural shaders, and generated geometry. The result includes a runtime hierarchy of pivots, sockets, and colliders so it can be animated. A staged pipeline (blockout through optimization) is vision-reviewed pass by pass, while deterministic Python scripts handle validation and gating. It is described as reconstruction-by-code, not photogrammetry, mesh extraction, or downloaded art packs.
Who it's for
- Developers who use Claude Code, Codex, or OpenCode and want Three.js models generated from reference images
- Teams that need code-only 3D assets with no mesh files and animation-ready hierarchy
- Users who need domain workflows such as CS2 weapon skins or animated characters, via plugins
Requirements
Requirements
- Node.js >= 18 and Git (for the CLI)
- Python >= 3.10 (for the reconstruction scripts)
- An agent host configured first: Hermes, Claude Code, Codex, or OpenCode (the plugin harness supports Claude Code, Codex, and OpenCode)
- Harness CLI 0.4.0 or newer for short plugin IDs, if using plugins
- Authorized Git access for the private environment plugin
Setup
Install the base skill
Preview the install, install into all detected hosts, then run doctor to inspect the base-skill links.
bashnpx --yes img2threejs@latest install --dry-run npx --yes img2threejs@latest install npx --yes img2threejs@latest doctorInstall into a single host
Use this to target just one detected host instead of all of them. The
--yesbelongs to npx, not to the installer.bashnpx --yes img2threejs@latest install --host claudeManual alternative
Clone the repo directly as the skill instead of using the CLI. Choose either this or the CLI for the same skill path, not both. A manual clone follows the default branch, not the CLI's pinned release.
bashgit clone https://github.com/img2threejs/img2threejs.git ~/.claude/skills/img2threejsInstall the plugin harness (optional)
Only needed if you want plugins. Installing the harness does not install the base skill.
bashnpx --yes @img2threejs/img2@latest install --yes npx --yes @img2threejs/img2@latest pluginsAdd domain plugins (optional)
Install CS2 and character plugins after harness setup, then verify.
bashimg2 add cs2 --yes img2 add character --yes img2 list img2 doctor img2 sync --check
Examples
Basic reconstruction in Claude Code
Prompt/img2threejs Rebuild the object in ./reference.png as a procedural Three.js model.
Keep its proportions, silhouette and colours. Follow the quality gates.
Report the output files, render-review evidence and any inferred regions.Expected output: Attach an image or give its path after installing the skill and restarting the agent session.
CS2 domain workflow
PromptUse img2threejs with the installed cs2 domain and ./reference.png.
Follow the cs2 profile and its family-specific reconstruction and review gates.Expected output: Names the cs2 profile explicitly; requires the CS2 plugin to be installed.
Animated character workflow
PromptUse img2threejs with the installed character plugin and ./reference.png.
Follow the animated-character profile. Do not claim animation readiness until its rig gates pass.Expected output: Uses the animated-character profile from the character plugin, with rigging and animation gates.
Pin the skill to a release
bashnpx --yes img2threejs@latest update --ref v2.0.0What it does: --ref accepts a semantic tag or a full 40-character commit SHA, not a branch.
Pros & cons
Pros
- Pro:Output is code-only with no mesh files, and demos run live in the browser
- Pro:Quality gates and detail inventory block generation until identity-defining details are mapped to components or materials
- Pro:Generated models include pivots, sockets, and colliders so they are ready to animate
- Pro:Optional plugins add CS2 and animated-character workflows, with an explicit image-to-GLB route
Cons
- Con:A single image cannot guarantee 100 percent likeness; the pipeline reports per-region confidence and may ask for more views
- Con:Requires an agent host with vision capability plus Node, Git, and Python; installation alone generates nothing
- Con:Several demos are marked as placeholder rather than final, and the environment plugin needs private repository access
Images
