react-native-vision-camera

๐Ÿ“ธ A powerful, high-performance React Native Camera library.

MIT License

Downloads
545.4K
Stars
7.1K
Committers
102

Bot releases are visible (Hide)

react-native-vision-camera - Release 4.0.0-beta.0

Published by mrousavy 8 months ago

4.0.0-beta.0 (2024-02-29)

โœจ Features

  • Add takeSnapshot() to PreviewView (da6a818)
  • Add CodeScanner pipeline (ImageAnalysis) (416f00f)
  • Allow setting custom format in ImageWriter (46a1568)
  • Give V4 ๐Ÿซด (e53af0b)
  • Implement native HardwareBuffer rendering for VideoPipeline (10e7708)
  • Shutter sound and stabilization (66b4c84)
  • Upload .apk as a GitHub artifact (#2575) (2c976d8)
  • Use HDR or NIGHT extensions if available (34f62ec)

๐Ÿ› Bug Fixes

  • Cancel focus on session close (#2578) (9af6e61)
  • Check for ImageAnalysis support (774148a)
  • Fix "Unknown AF/AE/AWB State" error (#2592) (fabf019)
  • Fix Precapture timed out after 5 seconds error (#2586) (369cb4a)
  • Fix SENSOR_INFO_PHYSICAL_SIZE possibly being null on usb devices (d890230)
  • Fix Frame Processor SIGSEV crash in VisionCameraScheduler::trigger by locking mutex in dispatchAsync (#2591) (55992bb)
  • Implement takeSnaphot on iOS (282f105)
  • Trigger measure and layout manually in PreviewView (#2588) (7ac6f4d)
  • Use runOnUiThread only if needed (d7b3e0a)

๐Ÿ“š Documentation

  • Fix toArrayBuffer example in Frame Processor Guide (#2595) (4c159af)
  • Update docs for qualityBalance (cbe76b6)
react-native-vision-camera - Release 3.9.0

Published by mrousavy 8 months ago

3.9.0 (2024-02-16)

'tis a big one ๐Ÿ˜ณ - VisionCamera 3.9.0 brings A TON of exciting new features :

๐Ÿ‘‰ focus(...) for Android ๐Ÿ‘†
๐Ÿ‘‰ flash for Android ๐Ÿ“ธ
๐Ÿ‘‰ enableFpsGraph for Android ๐Ÿ“ˆ
๐Ÿ‘‰ enableGpuBuffers for Android ๐Ÿ”ฅ
๐Ÿ‘‰ A fully rewritten CameraCaptureSession to fix various blackscreen issues on Android ๐Ÿš€
๐Ÿ‘‰ A fully rewritten PreviewView to fix stretching issues on Android ๐Ÿ–ผ๏ธ
๐Ÿ‘‰ AE/AF/AWB pre-capture focus for better quality photos on Android ๐Ÿ“ท
๐Ÿ‘‰ Faster photo capture with qualityPrioritization options (speed, balanced, quality) ๐Ÿƒ
๐Ÿ‘‰ Threading and Concurrency optimizations for faster Camera startup and switching speed ๐Ÿงต
๐Ÿ‘‰ Various issues fixed (maxImages have already been acquired, NullPointerException, Invalid PixelFormat, CameraDevice was already closed, ...) ๐Ÿ’ช

Full changelog:

โœจ Features

  • Flash for Android ๐Ÿฅณ๐Ÿ“ธ (#2558) (37398cc)
  • Implement focus() on Android (#2523) (fb1d82a)
  • Create persistent CaptureSession to avoid any blackscreen issues or errors (#2494) (5acc64e)
  • Add FPS Counter to Android (enableFpsGraph) (#2460) (9089014)
  • Configures capture options with qualityPrioritization flags to shoot photos faster (*_MODE_FAST) (#2558) (37398cc)
  • Add enableGpuBuffers property (#2557) (1a0bd8f), closes #2555
  • Synchronize Frame properly (#2501) (d8c95c9)
  • Add context to VisionCameraProxy (#2545) (24f43ef)
  • Allow focus calls to be cancelable (#2567) (4168d8f)
  • Bump org.jetbrains.kotlinx:kotlinx-coroutines-android from 1.5.2 to 1.7.3 (#2467) (fb96d00)
  • Use yuv by default if no pixelFormat is set (#2441) (11eb1f6)

๐Ÿ’จ Performance Improvements

  • Use existing cameraQueue instead of yet another Thread (#2459) (8c5b603)
  • Allow skipping pre-capture sequence if already focused (#2561) (a7701c8)
  • Use GPU/CPU optimized ImageReaders when possible (#2488) (f896831)
  • Fix double configuration flicker on fast device change (#2537) (b3a8827)

๐Ÿ› Bug Fixes

  • Fix PreviewView being stretched (#2519) (3192f5e) <-- this is a big one! ๐Ÿฅณ
  • Fix zoom not resetting in example app (395ee7a)
  • Fix photo not saving in example app on Android 13+ (#2522) (a4e241a)
  • Catch insufficient-storage errors (#2422) (b1fa065)
  • Enable processNestedWorklets to fix runAsync in example (#2449) (587f2b1)
  • Expose auto-focus system for Android (#2455) (b5eb01b)
  • Fix maxImages have been acquired error in Frame Processor (#2430) (7e2889c)
  • Fix NullPointerException in initFrameProcessorPlugin if plugin is not found (#2454) (02bc8a9)
  • Fix NullPointerException in VideoPipeline.removeRecordingSessionOutputSurface (#2453) (bdbcf05)
  • Fix pixelFormat being native when FP is set (#2450) (d64fc08)
  • Fix priority being ignored in some Format filters (#2456) (d9a3011)
  • Fix SharedArray JSI constructor allocating a new array instead of wrapping (#2444) (c911d25)
  • Fix Unable to retrieve jni environment. Is the thread attached? errors by using jni::ThreadScope (#2457) (33e2adc)
  • Fix Android C++ SharedArray logs (bc6f954)
  • Fix crash in toArrayBuffer() by properly acquiring a reference on AHardwareBuffer* (#2490) (ae75e22)
  • Fix HostObject destructors to make sure a JNI Environment is set up (#2462) (5f75b9e)
  • Prevent phone from going to sleep if Camera is active (#2421) (a739ca1)
  • Properly check HardwareBuffer usage flags before setting them (#2488) (f896831)
  • Refresh Permissions on AppState change (#2420) (97684af)
  • Remove unneeded synchronized keyword (f400487)
  • remove yarn in gitignore (5c5d629)
  • Use ThreadScope::WithClassLoader to also load custom JNI Types (#2461) (9e12975)
  • Add extra sanity-checks for CaptureRequest (#2571) (b105de0)
  • Fix nullable props (#2573) (bda43d3)
  • Replace deprecated RCTEventEmitter with UIManager (#2569) (57c6431)
  • Fix minFocusDistance being NaN on some emulators (e95264f)
  • Properly type Format Templates (#2499) (cd5fdd4)
  • Check if session is still valid before resetting AF after focus (#2550) (b7e24c4)
  • Fix "Invalid pixel format 35" HardwareBuffer crash (#2547) (a2a2e94)
  • Fix java.lang.NoSuchMethodError in FrameProcessor initializer (#2546) (1011c3f)
  • Fix 60 FPS crashing on some Samsungs (#2556) (4786885)
  • Fix VideoPipeline crash on Samsung (Disable USAGE_GPU_SAMPLED_IMAGE ImageReader) (#2555) (ad33dd9)
  • Return after configure error (14daaaa)
  • Use acquireLatestImage instead of acquireNextImage for CodeScanner (#2549) (ec7ce36)
  • Fix PreviewView stretching on Android (now finally a real fix) (#2564) (5df5ca9)
  • Take Orientation into account for PreviewView (#2565) (83c0184)
  • Fix Session has been closed; further changes are illegal error by using tryStopRepeating() (#2568) (129e21f)
  • Move PreviewView into SurfaceView to make it simpler (#2566) (bcd1264)

๐Ÿ“š Documentation

  • New Frame Processor Plugins docs (#2434) (4041ee8)
  • Use SVG PlayStore Button (aad7d2b)
  • Be more explicit about videoHeight/videoWidth (97168c6)
  • Be more explicit about video + preview link and add aspect ratio (14554fa)
  • Add react-native-vision-camera-face-detector to the FP plugin list (#2534) (0ed3aed)
react-native-vision-camera - Release 3.9.0-beta.6

Published by mrousavy 8 months ago

3.9.0-beta.6 (2024-02-15)

โœจ Features

๐Ÿ› Bug Fixes

  • Fix Session has been closed; further changes are illegal error by using tryStopRepeating() (#2568) (129e21f)
  • Move PreviewView into SurfaceView to make it simpler (#2566) (bcd1264)
react-native-vision-camera - Release 3.9.0-beta.5

Published by mrousavy 8 months ago

3.9.0-beta.5 (2024-02-15)

๐Ÿ› Bug Fixes

  • Fix PreviewView stretching on Android (now finally a real fix) (#2564) (5df5ca9)
  • Take Orientation into account for PreviewView (#2565) (83c0184)
react-native-vision-camera - Release 3.9.0-beta.4

Published by mrousavy 8 months ago

3.9.0-beta.4 (2024-02-14)

โœจ Features

  • Add context to VisionCameraProxy (#2545) (24f43ef)
  • Add enableGpuBuffers property (#2557) (1a0bd8f), closes #2555
  • Flash for Android ๐Ÿฅณ๐Ÿ“ธ (#2558) (37398cc)
  • Configures capture options with qualityPrioritization flags to shoot photos faster (*_MODE_FAST) (#2558) (37398cc)

๐Ÿ’จ Performance Improvements

  • Allow skipping pre-capture sequence if already focused (#2561) (a7701c8)
  • Fix double configuration flicker on fast device change (#2537) (b3a8827)

๐Ÿ› Bug Fixes

  • Check if session is still valid before resetting AF after focus (#2550) (b7e24c4)
  • Fix "Invalid pixel format 35" HardwareBuffer crash (#2547) (a2a2e94)
  • Fix java.lang.NoSuchMethodError in FrameProcessor initializer (#2546) (1011c3f)
  • Fix 60 FPS crashing on some Samsungs (#2556) (4786885)
  • Fix VideoPipeline crash on Samsung (Disable USAGE_GPU_SAMPLED_IMAGE ImageReader) (#2555) (ad33dd9)
  • Return after configure error (14daaaa)
  • Use acquireLatestImage instead of acquireNextImage for CodeScanner (#2549) (ec7ce36)

๐Ÿ“š Documentation

  • Add react-native-vision-camera-face-detector to the FP plugin list (#2534) (0ed3aed)
react-native-vision-camera - Release 2.16.8

Published by mrousavy 8 months ago

2.16.8 (2024-02-08)

๐Ÿ› Bug Fixes

  • Fix capture/no-valid-data thrown when calling stopRecording() on some Android devices (#2466) (377264d)
  • Revert: #1955 unbinding camera (#2528) (5651905)
react-native-vision-camera - Release 3.9.0-beta.3

Published by mrousavy 8 months ago

3.9.0-beta.3 (2024-02-08)

โœจ Features

react-native-vision-camera - Release 3.9.0-beta.2

Published by mrousavy 9 months ago

3.9.0-beta.2 (2024-02-07)

In this release I finally fixed the PreviewView stretching issue!! ๐Ÿ‘๐Ÿฅณ๐Ÿš€

๐Ÿ› Bug Fixes

  • Fix PreviewView being stretched (#2519) (3192f5e) <-- this is a big one! ๐Ÿฅณ
  • Fix zoom not resetting in example app (395ee7a)
  • Fix photo not saving in example app on Android 13+ (#2522) (a4e241a)
react-native-vision-camera - Release 3.9.0-beta.1

Published by mrousavy 9 months ago

3.9.0-beta.1 (2024-02-06)

โœจ Features

  • Create persistent CaptureSession to avoid any blackscreen issues or errors (#2494) (5acc64e)
  • Synchronize Frame properly (#2501) (d8c95c9)

๐Ÿ› Bug Fixes

  • Fix minFocusDistance being NaN on some emulators (e95264f)
  • Properly type Format Templates (#2499) (cd5fdd4)

๐Ÿ“š Documentation

  • Be more explicit about videoHeight/videoWidth (97168c6)
  • Be more explicit about video + preview link and add aspect ratio (14554fa)
react-native-vision-camera - Release 3.9.0-beta.0

Published by mrousavy 9 months ago

3.9.0-beta.0 (2024-02-01)

โœจ Features

  • Use GPU/CPU optimized ImageReaders when possible (#2488) (f896831)
  • Add FPS Counter to Android (enableFpsGraph) (#2460) (9089014)
  • Bump org.jetbrains.kotlinx:kotlinx-coroutines-android from 1.5.2 to 1.7.3 (#2467) (fb96d00)
  • Use yuv by default if no pixelFormat is set (#2441) (11eb1f6)

๐Ÿ’จ Performance Improvements

  • Use existing cameraQueue instead of yet another Thread (#2459) (8c5b603)

๐Ÿ› Bug Fixes

  • Catch insufficient-storage errors (#2422) (b1fa065)
  • Enable processNestedWorklets to fix runAsync in example (#2449) (587f2b1)
  • Expose auto-focus system for Android (#2455) (b5eb01b)
  • Fix maxImages have been acquired error in Frame Processor (#2430) (7e2889c)
  • Fix NullPointerException in initFrameProcessorPlugin if plugin is not found (#2454) (02bc8a9)
  • Fix NullPointerException in VideoPipeline.removeRecordingSessionOutputSurface (#2453) (bdbcf05)
  • Fix pixelFormat being native when FP is set (#2450) (d64fc08)
  • Fix priority being ignored in some Format filters (#2456) (d9a3011)
  • Fix SharedArray JSI constructor allocating a new array instead of wrapping (#2444) (c911d25)
  • Fix Unable to retrieve jni environment. Is the thread attached? errors by using jni::ThreadScope (#2457) (33e2adc)
  • Fix Android C++ SharedArray logs (bc6f954)
  • Fix crash in toArrayBuffer() by properly acquiring a reference on AHardwareBuffer* (#2490) (ae75e22)
  • Fix HostObject destructors to make sure a JNI Environment is set up (#2462) (5f75b9e)
  • Prevent phone from going to sleep if Camera is active (#2421) (a739ca1)
  • Properly check HardwareBuffer usage flags before setting them (#2488) (f896831)
  • Refresh Permissions on AppState change (#2420) (97684af)
  • Remove unneeded synchronized keyword (f400487)
  • remove yarn in gitignore (5c5d629)
  • Use ThreadScope::WithClassLoader to also load custom JNI Types (#2461) (9e12975)

๐Ÿ“š Documentation

react-native-vision-camera - Release 3.8.2

Published by mrousavy 9 months ago

3.8.2 (2024-01-18)

โœจ Features

  • SharedArray:wrapData:withSize init for iOS (#2410) (992934e)

๐Ÿ› Bug Fixes

  • Throw not-compatible-with-outputs error when adding both CodeScannerPipeline and VideoPipeline (#2411) (e21a1c2)
react-native-vision-camera - Release 3.8.1

Published by mrousavy 9 months ago

3.8.1 (2024-01-17)

โœจ Features

๐Ÿ› Bug Fixes

  • Fixes a crash on Android when using Frame Processor on API 29 (CPU + GPU flag use in PRIVATE/YUV) (#2408) (ba1d7ee)
  • Fixes a crash on Android when using frame.toArrayBuffer() due to the resulting HardwareBuffer being closed (#2408) (ba1d7ee)
  • Fix C++ build-error when trying to use JSITypedArray.h (#2396) (60f8a8c)
  • Make Frame properties readonly in Types (#2397) (e825e21)
  • Release MediaActionSound after playing (#2390) (bdad4e1)
  • Use property accessors on Frame (#2400) (773f278)
react-native-vision-camera - Release 3.8.0

Published by mrousavy 9 months ago

3.8.0 (2024-01-15)

Breaking change: Native Frame Processor Plugin constructors now take an additional argument: VisionCameraProxy. This can be used to create instances of SharedArray, see #2383 for more information.

โœจ Features

  • Add minFocusDistance prop to CameraDevice (#2392) (58ef21e)
  • Add zero-copy SharedArray type to Frame Processor Plugins (#2383) (29fe98c)

๐Ÿ› Bug Fixes

  • Avoid "CameraNotReady" errors when updating props in background (#2382) (a468602)
  • Fix CamcorderProfile out of range error (#2389) (17ae5fa)
  • Fix JNI TypedArray error (fe614a4)
  • Fix SharedArray name (d747933)

๐Ÿ“š Documentation

  • Add platform: iOS annotation to regionOfInterest prop (9ecc09c)
  • Fix typo (ec2f8c2)
  • Recommend [@latest](https://github.com/latest) CLI version (b9a69a2)
  • Update FrameProcessorPlugin's init method callsites (#2385) (84598c2)
  • Update SharedArray* type (ae7f5e2)
react-native-vision-camera - Release 3.7.1

Published by mrousavy 9 months ago

3.7.1 (2024-01-11)

โœจ Features

  • Re-throw error on JS side instead of just logging on native side (#2366) (34c5b11)

๐Ÿ› Bug Fixes

๐Ÿ“š Documentation

react-native-vision-camera - Release 2.16.7

Published by mrousavy 9 months ago

2.16.7 (2024-01-11)

๐Ÿ› Bug Fixes

  • Fix JSI Runtime Pointer being null in bridgeless mode (38ba240)
react-native-vision-camera - Release 3.7.0

Published by mrousavy 10 months ago

3.7.0 (2024-01-08)

Quite a big release again! ๐Ÿฅณ

Notable changes:

  1. If you use the CodeScanner API, make sure to use the new VisionCamera_enableCodeScanner flag for Android which makes sure the MLKit model always gets bundled! (see the docs) ๐Ÿ•ต๏ธ
  2. A ton of blackscreen and out of sync issues have been fixed on Android. See this PR.

โœจ Features

  • Add new enableCodeScanner prop to build.gradle to make sure CodeScanner always works (#2355) (5c99728)
  • Make enableCodeScanner expo config-plugin install the native dependency (#2348) (a8c16e3)
  • Make Frame thread-safe and improve error messages (#2327) (895f3ec)
  • Add two new format/ errors: invalid-video-stabilization-mode and format-required (#2354) (cc60ad2)
  • Support 60 FPS on Samsung devices (if available) (#2339) (0d21bc3)

๐Ÿ› Bug Fixes

  • Fix blackscreen issues and lifecycle when closing Camera (#2339) (0d21bc3)
  • Fix a scenario where the concurrent configure { ... } mechanism could drop important updates (#2339) (0d21bc3)
  • Fix Android lifecycle by allowing Android to close the CameraDevice when isActive=false (#2339) (0d21bc3)
  • Fix Android blackscreens by refactoring CameraSession setup (#2339) (0d21bc3)
  • Fix "photo/video is not enabled" errors (#2339) (0d21bc3)
  • Fix "maxImages (3) has already been acquired" error (#2352) (2cd22ad)
  • Fix "The given value for videoStabilizationMode could not be parsed" error (#2353) (833ffb8)
  • Fix crash when trying to console.log(frame) (#2335) (3dc7511)
  • Fix for inset of SENSOR_INFO_ACTIVE_ARRAY_SIZE for Android < 11 (#2306) (7905f2c)
  • Fix iOS native enableZoomGesture zoom logic (#2329) (30c4f9e)
  • Fix min/max exposure range on Android (#2304) (0d3ecd1)
  • Unwrap boxed JNI types directly (#2337) (ef4e9fa)
  • Validate input props (fps, hdr, torch, ...) instead of silently crashing (#2354) (cc60ad2)

๐Ÿ’จ Performance Improvements

  • Make getCameraPermission and getMicrophonePermission synchronous (#2302) (591cf30)
  • Don't re-create anything if session is closing down (#2339) (0d21bc3)

๐Ÿ“š Documentation

  • Add plugin by mgcrea/vision-camera-barcode-scanner (7241342)
  • Create pinch-to-zoom example for docs (2d84b7f)
react-native-vision-camera - Release 3.6.17

Published by mrousavy 10 months ago

3.6.17 (2023-12-14)

โœจ Features

๐Ÿ› Bug Fixes

๐Ÿ“š Documentation

react-native-vision-camera - Release 3.6.16

Published by mrousavy 10 months ago

3.6.16 (2023-12-12)

โœจ Features

  • Add width and height to VideoFile output (#2281) (9a187c6)
react-native-vision-camera - Release 2.16.6

Published by mrousavy 10 months ago

2.16.6 (2023-12-12)

๐Ÿ› Bug Fixes

react-native-vision-camera - Release 3.6.15

Published by mrousavy 10 months ago

3.6.15 (2023-12-12)

โœจ Features

  • Add onStarted and onStopped events (#2273) (4ee52d6)
  • Add format filter for iso (#2234) (52f78a1)
  • Support for C++ Frame Processor Plugins by publishing VisionCamera as a prefab (#2251) (248a08b)

๐Ÿ› Bug Fixes

  • Fix NoSuchElementException in getRecommendedBitRate (#2266) (a612eb9)
  • Fix Only the original thread that created a view hierarchy can touch it's views error (#2278) (2630650)
  • Fix out-of-memory crash in QR code scanner by closing Image (#2267) (9600a38)
  • Fix RN 0.73 error "'hasConstants' overrides nothing" at CameraDevicesManager.kt (#2264) (9949184)
  • Only close image once (df32d2c)
  • Only copy over C++ headers (6107a24)

๐Ÿ“š Documentation