Skip to content

Repository files navigation

ProCameraVitaEX

Advanced PS Vita camera homebrew — full manual control, gyro anti-shake, microphone audio, rear-touchpad pinch zoom, QR scanner with direct VPK install, and automatic performance boost.

Requires a modded PS Vita running HENkaku or Ensō (firmware 3.60 – 3.74). Will not run on stock firmware. Both front and rear cameras are fully supported.


What's new in v2.1

🎤 Microphone audio in videos — PCM stereo interleaved in the AVI file
📐 Horizon level indicator — gyroscope roll overlay keeps shots straight
🤚 Anti-shake shutter — gyro blocks the shutter if you're moving
⏱️ Selfie timer — 3 s / 5 s / 10 s countdown
🔍 Rear touchpad pinch-to-zoom — two fingers on the back panel
120 fps burst mode — switches camera to 320×240 @ 120 fps
💾 Settings persistence — EV, ISO, WB etc. survive app restarts
VPK install fixed — all PNG assets now pass Vita firmware validation

Features at a glance

Category Details
Manual exposure EV −2.0 → +2.0 (17 steps), ISO Auto / 100 / 200 / 400, Gain 0–16
Image quality Brightness, Contrast, Saturation, Sharpness, Noise Reduction
White Balance Auto / Daylight / Fluorescent / Tungsten
Color Effects Normal / Negative / B&W / Sepia / Blue / Red / Green
Night Mode Off / <10 lux / <100 lux / >100 lux
Anti-Flicker Auto / 50 Hz / 60 Hz
Backlight Comp On / Off
Zoom 1× – 4× hardware zoom; rear-touchpad pinch also controls zoom
Tap-to-focus Touch front screen → AE/AWB lock + gold focus bracket ring
Camera switch Front ↔ Rear — mirror auto-enabled for front
Rule-of-thirds Optional grid overlay
Horizon level Gyro-based roll indicator (green < 3°, yellow < 15°, red > 15°)
Anti-shake Gyro blocks shutter while the device is moving
Selfie timer 3 s / 5 s / 10 s countdown before shutter fires
Burst mode 120 fps @ 320×240 for fast-action capture
QR Scanner 640×480 threaded decode, VPK download+install, browser launch
Photo JPEG capture → ux0:DCIM/ProCameraVitaEX/
Video MJPEG + PCM audio AVI 1.0 — plays on Vita Photos & desktop players
Gallery Thumbnail grid, full-screen view, delete
Settings All camera params saved on exit, restored on next launch
Performance Overclock to 444 / 222 / 222 / 166 MHz + 192 MB heap on startup

Controls

Photo mode

Button Action
Cross Take photo (anti-shake checked first; countdown if timer active)
Square Switch front ↔ rear camera
Triangle Toggle HUD on/off
L Trigger EV − (darker)
R Trigger EV + (brighter)
D-Pad Up / Down Zoom in / out
D-Pad Left / Right Cycle mode: Photo → Video → QR → Gallery
Start Cycle selfie timer: OFF → 3 s → 5 s → 10 s
Circle Toggle Night Mode
Select Toggle rule-of-thirds grid
L3 (left stick click) Toggle horizon level indicator
R3 (right stick click) Toggle 120 fps burst mode (320×240)
Front touch Tap preview to set focus / exposure point
Rear touchpad Two-finger pinch / spread to zoom in / out
Bottom toolbar Tap icon to open its settings slider
Settings slider Drag up/down to adjust value; tap outside to close

Video mode

Same as Photo mode, except:

Button Action
Cross Start / Stop recording

Audio is recorded from the built-in microphone automatically. On PSTV (no mic) the video is recorded without audio.

QR Scanner mode

Button Action
D-Pad Left Back to Photo mode
Cross Show "hold steady" reminder

Point at any QR code — decoding runs on a background thread, preview stays smooth.

Scanned payload Action taken
URL ending in .vpk Downloads to ux0:data/ProCameraVitaEX/downloads/, installs via ScePromoterUtil
Any http:// / https:// URL Opens in the PS Vita system browser
Local path pointing to a .vpk Installs directly from storage
Plain text Shown as an on-screen toast

Why it beats VitaShell's QR scanner: full 640×480 feed (vs 320×240), background thread so preview never drops, direct VPK install without leaving the app, HTTPS supported.

Gallery mode

Button Action
D-Pad Left / Right Previous / Next photo (full-screen view)
L / R Trigger Previous / Next page (grid view)
Circle Back to grid from full-screen
Triangle Delete current photo
Select Re-scan DCIM directory
Touch Tap thumbnail to open full-screen
D-Pad Right Back to Camera

Performance

On every launch the app sets the system to maximum homebrew-safe clocks and allocates a large heap:

Resource Stock ProCameraVitaEX
ARM CPU 333 MHz 444 MHz
GPU 111 MHz 222 MHz
Bus 111 MHz 222 MHz
XBAR 83 MHz 166 MHz
Newlib heap ~32 MB default 192 MB

sceKernelPowerTick() is called every frame — the screen will never dim or sleep while the camera is running.


File locations on Vita

Content Path
Photos ux0:DCIM/ProCameraVitaEX/IMG_YYYYMMDD_HHMMSS_NNN.jpg
Videos ux0:DCIM/ProCameraVitaEX/Video/VID_YYYYMMDD_HHMMSS.avi
VPK downloads (temp) ux0:data/ProCameraVitaEX/downloads/
Settings ux0:data/ProCameraVitaEX/settings.bin

Building from source

Prerequisites

Tool Notes
VitaSDK Set $VITASDK env var to the install path
CMake ≥ 3.10 CMake 4.x also works (compat shim baked into CMakeLists)
Python 3 + Pillow For generating LiveArea PNG assets (pip install Pillow)
git For fetching QUIRC
Linux / macOS / devkitPro MSYS2 VitaSDK cross-compiler

Quick build

# 1. Clone
git clone https://github.com/Zushikina-kun/ProCameraVitaEX.git
cd ProCameraVitaEX

# 2. Fetch QUIRC (one-time — already vendored if you clone the full repo)
bash scripts/setup_quirc.sh

# 3. Generate LiveArea PNG assets (forces correct 8-bit palette depth)
python3 scripts/gen_vita_assets.py

# 4. Build
bash scripts/build.sh release

The script produces ProCameraVitaEX.vpk in the project root.

Manual CMake build

mkdir build && cd build
cmake .. \
  -DCMAKE_BUILD_TYPE=Release \
  -DCMAKE_TOOLCHAIN_FILE=$VITASDK/share/vita.toolchain.cmake
make -j$(nproc)

Note: CMAKE_POLICY_VERSION_MINIMUM=3.5 is set inside CMakeLists.txt so you do not need to pass it on the command line.

Verify VPK before installing

python3 scripts/verify_vpk_pngs.py

This checks every PNG inside the built VPK for depth=8 colortype=3. A single wrong PNG causes a 0x8010113D install failure at 99% — run this before copying to your Vita.

Installing on Vita

  1. Copy ProCameraVitaEX.vpk to ux0:data/ via FTP or USB
  2. Open VitaShell, navigate to the VPK, press Cross to install
  3. Launch ProCameraVitaEX from LiveArea

LiveArea assets

All assets are pre-generated and included in the repo. To regenerate them (e.g. to add your own artwork):

python3 scripts/gen_vita_assets.py
File Size Notes
sce_sys/icon0.png 128 × 128 App icon — must be opaque (no alpha)
sce_sys/pic0.png 960 × 544 Fullscreen loading image — mandatory, VPK rejected without it
sce_sys/livearea/contents/bg0.png 840 × 500 LiveArea background — must be named bg0, not bg
sce_sys/livearea/contents/startup.png 280 × 158 Start button image

All must be 8-bit palette PNG (depth=8, colortype=3). The gen_vita_assets.py script guarantees this by building the IHDR chunk manually.


Project structure

ProCameraVitaEX/
├── CMakeLists.txt
├── ProCameraVitaEX.vpk          ← pre-built, ready to install
├── PSVITA_VPK_ISSUES.md         ← developer reference for common pitfalls
├── include/
│   ├── common.h                 – AppState, shared constants, all SDK includes
│   ├── camera_controls.h        – Full SceCamera API wrapper
│   ├── motion_sensor.h          – SceMotion: anti-shake + horizon level
│   ├── settings.h               – Persistent settings load/save
│   ├── ui.h                     – HUD, sliders, EV scale, QR overlay
│   ├── photo.h                  – JPEG capture (SceJpegEnc)
│   ├── video_record.h           – MJPEG+PCM AVI 1.0 muxer
│   ├── qr_scanner.h             – QUIRC threaded decode + VPK install
│   ├── network.h                – HTTP/HTTPS download
│   ├── renderer.h               – YUV422→RGBA pipeline, digital zoom
│   └── gallery.h                – Photo browser
├── src/
│   ├── main.c                   – Entry point, overclock, main loop
│   ├── camera_controls.c        – All sceCameraGet/Set wrappers
│   ├── motion_sensor.c          – SceMotion init, shake detect, horizon draw
│   ├── settings.c               – Binary config file read/write
│   ├── ui.c                     – HUD, bottom toolbar, panel sliders
│   ├── photo.c                  – SceJpegEnc YUV422 → JPEG
│   ├── video_record.c           – AVI muxer (video + audio interleave)
│   ├── qr_scanner.c             – QUIRC on dedicated thread
│   ├── network.c                – SceNet/SceHttp + progress bar
│   ├── renderer.c               – vita2d camera preview + overlays
│   └── gallery.c                – Thumbnail grid + full-screen viewer
├── third_party/quirc/lib/       – QUIRC QR library (vendored)
├── sce_sys/                     – LiveArea assets (pre-generated)
├── scripts/
│   ├── gen_vita_assets.py       – Generate correct 8-bit palette PNGs
│   ├── verify_vpk_pngs.py       – Validate PNGs inside built VPK
│   ├── setup_quirc.sh           – Fetch QUIRC from GitHub
│   └── build.sh                 – One-shot build script
└── cmake/
    └── FindQUIRC.cmake

Known limitations

  • Fixed-focus cameras — The Vita hardware has no autofocus lens. Tap-to-focus locks AE/AWB to the tapped region but cannot move a physical lens element.
  • Max resolution 640 × 480 — Hardware limit of both cameras. 320×240 @ 120 fps is also available via burst mode.
  • CPU-based video encoding — No public hardware H.264 encoder in vitasdk. Video is MJPEG + PCM in an AVI container, which is larger than H.264 but plays on every media player without transcoding.
  • No audio on PSTV — PlayStation TV has no microphone. The app detects this and records video-only silently.
  • VPK QR install requires HENkakuScePromoterUtil is only accessible on modded firmware. The stub is weak-linked so the app loads on any Vita, but the install action shows an error toast on stock firmware.
  • Wi-Fi required for downloads — No 3G/4G API is available to homebrews.

Credits


License

Source code: MIT — see LICENSE QUIRC: MIT (see third_party/quirc/) vita2d: MIT

About

Advanced PS Vita camera homebrew — full manual control, QR scanner with direct VPK install, and automatic performance boost.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages