Generate interactive 3D meshes from your camera in real time. Point your webcam at an object, click capture, and get a textured 3D mesh you can orbit, zoom, and pan.
Powered by TripoSR (Stability AI) for single-view 3D reconstruction.
# Requires: uv, Python 3.10-3.12, PyTorch
bash run.shThen open http://localhost:8000.
- Python 3.10-3.12 (managed automatically by
uv) - uv — fast Python package manager
- PyTorch — install before running:
# macOS (MPS) uv pip install torch # Linux (CUDA 12.1) uv pip install torch --index-url https://download.pytorch.org/whl/cu121 # CPU only uv pip install torch --index-url https://download.pytorch.org/whl/cpu
The first run downloads ~1.5GB of model weights from HuggingFace.
- Browser captures a frame from your camera
- Backend removes the background (rembg/U2Net)
- TripoSR generates a 3D mesh with vertex colors
- GLB mesh is sent back and rendered with Three.js
- Live camera with rear-camera preference on mobile
- Auto-capture mode (every 5 seconds)
- Interactive 3D viewer — orbit, zoom, pan with mouse/touch
- Resolution control — Fast (128), Standard (256), High (512)
- Resizable split view — drag the divider between camera and viewer
- Auto device detection — uses CUDA, MPS (Apple Silicon), or CPU
├── backend/
│ ├── main.py # FastAPI app and endpoints
│ ├── model_manager.py # TripoSR model singleton
│ └── mesh_generator.py # Image preprocessing and mesh generation
├── frontend/
│ ├── index.html # Split-view layout
│ ├── css/styles.css # Dark theme UI
│ └── js/
│ ├── app.js # Main orchestrator
│ ├── camera.js # Camera capture
│ ├── viewer.js # Three.js 3D viewer
│ └── api.js # Backend API client
├── patches/ # PyMCubes compatibility patch for TripoSR
├── pyproject.toml # Dependencies (uv/pip)
└── run.sh # One-command setup and launch