Releases: mrousavy/react-native-vision-camera
Release 5.0.4
Release 5.0.3
Release 5.0.2
5.0.2 (2026-04-21)
✨ Features
🐛 Bug Fixes
- Add 'worklet' directive to getCurrentThreadMarker (#3745) (1deb582)
- ci: fix github runners to run on GH for now (#3737) (ced5456)
- Remove
createNormalizedMeteringPoint(...)1:1 export- preferVisionCamera.createNormalizedMeteringPoint(...)(#3742) (c460f9f) - Use
DynamicRangeBitDepthto avoid unsafe enum case names (#3738) (ae769fe)
📚 Documentation
Release 5.0.0
🎬 VisionCamera V5
The biggest release in VisionCamera's history.
V5 is a new foundation: fully rewritten to Nitro Modules, redesigned around a new Constraints API, and flexible enough to unlock workflows that were awkward or impossible in V4. Five years in the making.
👉 Read the full deep-dive: blog.margelo.com/whats-new-in-visioncamera-v5
📚 New docs: visioncamera.margelo.com
✨ Highlights
- 🚄 Fully rewritten to Nitro — individual native calls are now up to 15x faster than Turbo-Modules, 60x faster than Expo-Modules
- 🧹 ~3,000 lines of hand-written JSI/C++ deleted — bye bye
SIGSEGVandSIGABRT - 🎯 New Constraints API — express intent, let the Camera negotiate the best supported configuration
- 📸 In-memory
Photoobjects — no more temp files for every capture - 🌊 Depth streaming via
DepthOutput(LiDAR, ToF, Infrared, disparity) - 🖼️ RAW capture (Adobe DNG & Apple ProRAW)
- 👯 Multi-Cam sessions — front + back simultaneously
- 🧩 Modular packages — pick only what you need
- 📖 Brand new documentation site with full API reference
⚠️ Breaking Changes
V5 is a major version bump. Expect migration work. Highlights:
Formats API removed
The entire Formats API (useCameraFormat, format prop) is gone. Use the new Constraints API instead:
// ❌ V4
const format = useCameraFormat(device, [
{ fps: 60 },
{ videoHdr: true },
{ videoResolution: { width: 3840, height: 2160 } }
])
<Camera device="back" format={format} fps={60} videoHdr />
// ✅ V5
<Camera
device="back"
constraints={[
{ fps: 60 },
{ videoDynamicRange: CommonDynamicRanges.ANY_HDR }
]}
/>Outputs are now separate objects
photo={true} / video={true} boolean props have been replaced by explicit Output objects:
// ❌ V4
<Camera photo video />
// ✅ V5
const photoOutput = usePhotoOutput()
const videoOutput = useVideoOutput()
<Camera outputs={[photoOutput, videoOutput]} />takePhoto() → capturePhoto()
Capture methods moved from the Camera ref to the individual Output, and now return an in-memory Photo instead of writing to disk:
// ❌ V4
const file = await cameraRef.current.takePhoto()
// ✅ V5
const photo = await photoOutput.capturePhoto({})
const image = await photo.toImageAsync() // display directly via react-native-nitro-imageBarcode Scanner moved to its own package
CodeScanner is no longer in core. Install react-native-vision-camera-barcode-scanner separately. Now powered by MLKit on both iOS and Android for consistent behavior.
Frame Processor plugins are now Nitro Modules
Plugin authors: no more [String: Any?] or untyped maps. Plugins now use Nitro's typing system for full type-safety on params and return values. See Native Frame Processor Plugins.
Default Worklets runtime switched
The default Worklets implementation is now react-native-worklets (Software Mansion) instead of react-native-worklets-core. You can now mutate Reanimated SharedValues directly from a Frame Processor.
🚀 New Features
Full rewrite to Nitro Modules
- Entire Frame Processor implementation rewritten in plain Swift/Kotlin, replacing ~3,000 LOC of hand-written JSI/C++
CameraDeviceis now a lazyHybridObject— properties are fetched on access (~15x faster than Turbo-Modules, ~60x faster than Expo-Modules)- Faster startup, lower camera latency, no more threading crashes
The new Constraints API
- Express intent via
Constraint[], the Camera negotiates a matching configuration - On iOS: internally filters
AVCaptureDevice.Format - On Android: uses
CameraInfo.isSessionConfigSupported(...) - Constraints are priority-ordered by array position
- Camera features exposed upfront on
CameraDevice(e.g.supportedFPSRanges,getSupportedResolutions(...))
In-memory Photo capture
capturePhoto()returns aPhotoobject held in memory (plus EXIF + camera data)- Display directly via
react-native-nitro-imagewithout any disk I/O - Significantly more responsive photography UX
Higher resolutions (including 8K on iOS)
- Resolution now correctly depends on attached outputs
- Fewer outputs = higher possible resolutions
- 8K Photo capture now possible on supported iOS devices
Manual AE / AF / AWB
Pro-photography controls for Exposure, Focus, and White Balance:
await controller.setFocusLocked(0.3)
await controller.setExposureLocked(minDuration, maxISO)
await controller.setWhiteBalanceLocked({ redGain: 1.0, greenGain: 0.1, blueGain: 0.1 })Full Dynamic Range API (SDR / HDR / Log)
Replaces the simple videoHdr switch. Supports HLG_BT2020, Apple Log, and custom bit-depth / color-space / color-range combinations via the Constraints API.
Enhanced focusTo(...)
New options: modes (AE/AF/AWB), adaptiveness ('locked' | 'continuous'), autoResetAfter, responsiveness ('snappy' | 'steady'). Also works now in <SkiaCamera />. 🎉
Coordinate System Conversions
First-class support for converting between Preview, Frame, and Camera coordinate spaces. Perfect for drawing bounding boxes over detected faces/barcodes.
Depth Data Streaming
useDepthOutput streams depth-* frames (LiDAR / ToF / Infrared) or disparity-* frames (dual/triple virtual cameras).
RAW Capture
Adobe DNG and Apple ProRAW capture. See RAW Photos.
Imperative API
Full programmatic control for advanced use-cases:
const session = await VisionCamera.createCameraSession(false)
await session.configure([{ input: device, outputs: [...], constraints: [] }])
await session.start()Multi-Cam Sessions
Stream from front + back (or any combination of) CameraDevices simultaneously to multiple outputs. PiP previews, synchronized recording, the works.
Native Object Output (iOS)
New CameraObjectOutput for detecting QR codes, faces, human bodies, and more via AVCaptureMetadataOutput — no ML dependency required.
Extensible: custom native CameraOutputs
Implement NativeCameraOutput in your own Nitro Module and attach it to a VisionCamera session without forking. Custom HDR pipelines, ML pipelines, anything.
📦 New & Restructured Packages
VisionCamera is now split into focused packages. Install only what you need:
| Package | Purpose |
|---|---|
react-native-vision-camera |
Core: sessions, <Camera />, Photo/Video/Frame/Depth outputs |
react-native-vision-camera-barcode-scanner |
MLKit barcode scanner (iOS + Android) |
react-native-vision-camera-location |
Location EXIF/metadata attachment |
react-native-vision-camera-resizer |
🆕 GPU-accelerated frame resizer (~5x faster than SIMD) |
react-native-vision-camera-skia |
Skia preview with shaders/effects |
react-native-vision-camera-worklets |
Frame Processor worklets (now backed by react-native-worklets) |
🆕 react-native-vision-camera-resizer
GPU-accelerated compute shader (Metal on iOS, Vulkan on Android) for:
- Frame resizing
- YUV → RGB conversion
- Pixel packing
- Data type conversions
- Cropping for ML pipelines (ONNX, TFLite, etc.)
Benchmarked at ~5x faster than the CPU/SIMD-based vision-camera-resize-plugin.
📥 Installation
npm i react-native-nitro-modules react-native-nitro-image
npm i react-native-vision-camera@5For specific features:
# Barcode scanning
npm i react-native-vision-camera-barcode-scanner
# GPU frame resizer for ML pipelines
npm i react-native-vision-camera-resizer
# Frame Processors
npm i react-native-vision-camera-worklets react-native-worklets📚 Documentation
V5 ships with a completely new documentation site:
- 🏠 Landing: visioncamera.margelo.com
- 📖 Full API reference for every public type
- 🎯 Constraints API guide
- 🧭 Coordinate Systems
- 🖼️ RAW Photos
- 🧩 Native Frame Processor Plugins
🙏 Acknowledgments
- The Software Mansion team for
react-native-workletscollaboration - Everyone who tested V5 betas, filed issues, and kept the pressure on for five years
- The entire React Native community — you're the reason this library exists
Built by Margelo. Need custom camera work? Get in touch.
🔗 Links
- 📝 Full blog post
- 📚 Documentation
- 🐛 Report issues
- 💬 [Discussions](https://github.com/mrousavy/react...
Release 4.7.3
Release 4.7.2
Release 4.7.1
Release 4.7.0
Release 4.6.4
4.6.4 (2025-02-20)
🐛 Bug Fixes
- Don't send
onOrientationChangedevent if phone is flat on Android (#3429) (7456c00) - Fix
InitializationExceptionand rethrow inonErrorcallback (#3179) (#3385) (b194ef1) - Fix orientation actually being unknown (3a265c8)
- Fix orientation updating to
portraitwhen phone is flat (#3423) (85a3024) - Fix React Native 77 Android build failure by
LifecycleOwner(#3394) (6501b63), closes #3380 - Request the current location if
lastKnownLocationis null (#3358) (b687014) - Simplify logic and also catch extension manager error (#3390) (0271e9e)