GTA PS2 Model Viewer

Open source · MIT

Weapon models from your own PS2 discs.

A script that pulls the guns out of GTA III, Vice City and San Andreas disc images, and a 120 Hz viewer that shows them side by side. A JSON file turns the viewer into a camera rig that renders video.

Weapons
20 models, 3 games
Viewer
Electron + three.js, 119.6 fps average at a 120 Hz target
Extraction
34 s, no GUI, disc images are read-only
Capture
JSON to MP4, deterministic, any fps

Footage

Rendered by the viewer itself, 1080p at 60 fps.

Gun hall tour. A camera path through the hall, with orbits around the San Andreas Colt 45, the GTA III shotgun and the San Andreas AK-47. 25 s, 15 MB.
Same weapon, three games. The Colt 45, M16 / M4 and AK-47 lined up GTA III, Vice City, San Andreas from left to right. 18 s, 4 MB.

Screenshots

Captured from the running viewer.

The viewer's hall: three pedestals with a Colt 45 each for GTA III, Vice City and San Andreas, with a frame-rate readout in the corner showing 120 fps and a key reference at the bottom right.
The hall. One lane per game, one column per weapon. The readout shows frame rate against the 8.33 ms budget of a 120 Hz display.
Close view of the San Andreas AK-47 with its wooden stock and blocky PS2 texture, labelled AK-47, San Andreas.
Focus view. Click a gun or press Tab and the camera glides to it.
The GTA III shotgun on its pedestal seen from the side, with other guns on pedestals behind it, labelled Shotgun, GTA III.
The GTA III shotgun. All of III's weapons come from a single model file.

How it works

From disc to viewer in five steps

  1. Read the ISO 9660 disc image directly. Nothing is mounted or modified.
  2. Find the weapon files: one multi-part file in GTA III, per-weapon files inside the IMG archive in Vice City and San Andreas.
  3. Convert PS2-native geometry to plain RenderWare geometry with aap's open-source convdff.
  4. Unswizzle the PS2 textures to PNG, then write OBJ and MTL files.
  5. The viewer loads them, stands them upright, scales them to one size and lets you walk around.

Set up

Bring your own discs

No game files, models or textures are in the repository. You need Node.js 22+, Python 3.9+, git and a C++ compiler on PATH.

git clone https://github.com/devin-thomas/gta-ps2-model-viewer
cd gta-ps2-model-viewer
npm install
python tools/extract.py --gta3 "GTA III.iso" \
  --vc "Vice City.iso" --sa "San Andreas.iso"
npm start

On Windows, double-click Gun Viewer.cmd after extraction. Any subset of the three games works.

Limits