Vision Camera πŸ“Έ The Camera library that sees the vision.

Overview

Vision Camera



πŸ“Έ The Camera library that sees the vision.
npm i react-native-vision-camera
npx pod-install
Buy Me a Coffee at ko-fi.com



Documentation

Features

  • Photo, Video and Snapshot capture
  • Customizable devices and multi-cameras (smoothly zoom out to "fish-eye" camera)
  • Customizable FPS
  • Frame Processors (JS worklets to run QR-Code scanning, facial recognition, AI object detection, realtime video chats, ...)
  • Smooth zooming (Reanimated)
  • Fast pause and resume
  • HDR & Night modes

See the example app

Example

function App() {
  const devices = useCameraDevices('wide-angle-camera')
  const device = devices.back

  if (device == null) return <LoadingView />
  return (
    <Camera
      style={StyleSheet.absoluteFill}
      device={device}
      isActive={true}
    />
  )
}

Adopting at scale

This library helped you? Consider sponsoring!

VisionCamera is provided as is, I work on it in my free time.

If you're integrating VisionCamera in a production app, consider funding this project and contact me to receive premium enterprise support, help with issues, prioritize bugfixes, request features, help at integrating VisionCamera and/or Frame Processors, and more.


πŸš€ Get started by setting up permissions!

Comments
  • πŸ› JNI Crash when trying to use multiple Frame Processor Plugins in a single Frame Processor

    πŸ› JNI Crash when trying to use multiple Frame Processor Plugins in a single Frame Processor

    Question

    Hi,

    Hi created two test plugins, (Plugin1, Plugin2) based on the ExamplePlugin.

    They have been added a to Package and added to the MainApplication as per the examples provided.

    In my App I call both of them here, which causes the app to consistently crash with the following error:

    2021-09-14 21:17:03.138 12726-12883/com.meshcameratest A/.meshcamerates: java_vm_ext.cc:577] JNI DETECTED ERROR IN APPLICATION: can't call java.lang.Object com.meshcameratest.frameprocessors.ExamplePlugin1.callback(androidx.camera.core.ImageProxy, java.lang.Object[]) on instance of com.meshcameratest.frameprocessors.ExamplePlugin2
        java_vm_ext.cc:577]     in call to CallObjectMethodV
        java_vm_ext.cc:577]     from void com.mrousavy.camera.CameraView.frameProcessorCallback(androidx.camera.core.ImageProxy)
    

    The crash will always occur on the second call regardless of order. No crash occurs if I run call just a single plugin.

    It's very possible I'm missing some fundamental understanding of what you can and cannot do within a worklet, hence this is phrased as a question rather than a bug.

    Any guidance appreciated.

    Example repo available at https://github.com/ldstein/MeshCameraTest

    What I tried

    • Register plugins directly in onCreate
    • Moved packages around
    • Clear cache in metro, gradle
    • Ensure react-reanimated plugin + setup is complete

    VisionCamera Version

    2.7.0

    Additional information

    πŸ› bug πŸ€– android 
    opened by ldstein 40
  • πŸ› Android unknown crash

    πŸ› Android unknown crash

    device id of undefined

    Camera.tsx

      static getDerivedStateFromProps(props: CameraProps, state: CameraState): CameraState | null {
        const newCameraId = props.device.id;
        if (state.cameraId !== newCameraId) return { ...state, cameraId: newCameraId };
        return null;
      }
    
    

    my code check

    if(device && device.id) {
        console.log(device.id)
      }
    

    crash app

    android 10 xiaomi note 7

    πŸ› bug πŸ€– android 
    opened by bairock 37
  • πŸ› Vision Camera crashes when built with Xcode 14

    πŸ› Vision Camera crashes when built with Xcode 14

    What were you trying to do?

    I was trying to build my app with Xcode 14.

    Reproduceable Code

    No super fancy code. Simply render the camera with a frame processor. I'm using QR code scanner:
    
    
    const [frameProcessor, barcodes] = useScanBarcodes([BarcodeFormat.CODE_128])
    
    return (
        <Camera
           device={device}
           isActive={isActive}
           frameProcessorFps={5}
           frameProcessor={frameProcessor}
           style={StyleSheet.absoluteFillObject}
        />
    )
    

    What happened instead?

    The app crashed with an error from HostFunction.

    I can confirm that code works as expected when built with Xcode 13.

    Relevant log output

    2022-09-15 10:13:26.797643+0200 x[6471:486752] [native] VisionCamera.didSetProps(_:): Updating 13 prop(s)...
    2022-09-15 10:13:26.797882+0200 x[6471:487061] [native] VisionCamera.configureCaptureSession(): Configuring Session...
    2022-09-15 10:13:26.797894+0200 x[6471:487061] [native] VisionCamera.configureCaptureSession(): Initializing Camera with device com.apple.avfoundation.avcapturedevice.built-in_video:0...
    2022-09-15 10:13:26.797906+0200 x[6471:487061] [native] VisionCamera.configureCaptureSession(): Adding Video input...
    2022-09-15 10:13:26.798369+0200 x[6471:487075] FrameProcessorBindings: Setting new frame processor...
    2022-09-15 10:13:26.798393+0200 x[6471:487075] FrameProcessorBindings: Adapting Shareable value from function (conversion to worklet)...
    2022-09-15 10:13:26.798517+0200 x[6471:487075] FrameProcessorBindings: Successfully created worklet!
    2022-09-15 10:13:26.798554+0200 x[6471:487097] FrameProcessorBindings: Converting worklet to Objective-C callback...
    2022-09-15 10:13:26.799270+0200 x[6471:487097] FrameProcessorBindings: Frame processor set!
    2022-09-15 10:13:26.838111+0200 x[6471:487061] [native] VisionCamera.configureCaptureSession(): Adding Video Data output...
    2022-09-15 10:13:26.838707+0200 x[6471:487061] [native] VisionCamera.invokeOnInitialized(): Camera initialized!
    2022-09-15 10:13:26.838926+0200 x[6471:487061] [native] VisionCamera.configureCaptureSession(): Session successfully configured!
    2022-09-15 10:13:26.839396+0200 x[6471:487061] [native] VisionCamera.configureFormat(): Configuring Format...
    2022-09-15 10:13:26.839401+0200 x[6471:487061] [native] VisionCamera.configureDevice(): Configuring Device...
    2022-09-15 10:13:26.839427+0200 x[6471:487061] [native] VisionCamera.configureDevice(): Device successfully configured!
    2022-09-15 10:13:26.839689+0200 x[6471:487061] [native] VisionCamera.didSetProps(_:): Starting Session...
    2022-09-15 10:13:27.007614+0200 x[6471:487061] [native] VisionCamera.didSetProps(_:): Started Session!
    libc++abi: terminating with uncaught exception of type facebook::jsi::JSError: Exception in HostFunction: Javascript worklet error
    
    Error: Javascript worklet error
        at _f (native)
    
    Error: Exception in HostFunction: Javascript worklet error
    
    Error: Javascript worklet error
        at _f (native)
        at _f (native)
    terminating with uncaught exception of type facebook::jsi::JSError: Exception in HostFunction: Javascript worklet error
    
    Error: Javascript worklet error
        at _f (native)
    
    Error: Exception in HostFunction: Javascript worklet error
    
    Error: Javascript worklet error
        at _f (native)
        at _f (native)
    (Recorded stack frame) 
    
    
    I've debugged the code and it crashes in FrameProcessorUtils.mm:
    
    cb.callWithThis(runtime, cb, jsi::Object::createFromHostObject(runtime, frameHostObject));
    

    Null pointer exception

    
    
    ### Device
    
    iPhone 13
    
    ### VisionCamera Version
    
    2.14.1
    
    ### Additional information
    
    - [ ] I am using Expo
    - [X] I have read the [Troubleshooting Guide](https://mrousavy.github.io/react-native-vision-camera/docs/guides/troubleshooting)
    - [X] I agree to follow this project's [Code of Conduct](https://github.com/mrousavy/react-native-vision-camera/blob/main/CODE_OF_CONDUCT.md)
    - [X] I searched for [similar issues in this repository](https://github.com/mrousavy/react-native-vision-camera/issues) and found none.
    πŸ› bug 
    opened by jpudysz 34
  • πŸ›  Frame Processor threw an error: Value is undefined, expected an Object

    πŸ› Frame Processor threw an error: Value is undefined, expected an Object

    What were you trying to do?

    I'm trying to integrate this community plugin : https://github.com/rodgomesc/vision-camera-code-scanner But I'm unable to make it work on iOS. It works great on Android though. I have tried other community plugin but the same error appear. In fact event a frame processor function with no code in it makes the error appear. I've also tried different version react-native-vision-camera, since some changes has been made since the last version of vision-camera-code-scanner.

    Reproduceable Code

    const ScanBarCodeScreen = (props: NavigationProps) => {
      const [hasPermission, setHasPermission] = useState(false)
      const devices = useCameraDevices()
      const device = devices.back
    
      const frameProcessor = useFrameProcessor((frame) => {
        'worklet'
        console.log('hello')
      }, [])
    
      const isFocused = useIsFocused()
    
      useEffect(() => {
        (async () => {
          const status = await Camera.requestCameraPermission()
          setHasPermission(status === 'authorized')
        })()
      }, [])
    
      return (
        <>
          <StatusBar backgroundColor={Theme.Color.White} barStyle="dark-content" />
          <View
            style={{
              flex: 1,
              flexDirection: 'column',
              backgroundColor: 'black'
            }}
          >
            <SafeAreaView
              style={{
                flex: 1,
                justifyContent: 'space-between',
                alignItems: 'center'
              }}
            >
              {device != null && hasPermission && (
                <Camera
                  style={StyleSheet.absoluteFill}
                  device={device}
                  isActive={isFocused}
                  frameProcessor={frameProcessor}
                  frameProcessorFps={1}
                />
              )}
            </SafeAreaView>
          </View>
        </>
      )
    }
    

    What happened instead?

    As soon as I arrive on my screen, and after giving permission to use the device camera, I get the error Frame Processor threw an error: Value is undefined, expected an Object at every refresh.

    The app does not crash but I obviously cannot use the frame processor.

    Relevant log output

    FrameProcessorBindings: Creating Runtime Manager...
    FrameProcessorBindings: Runtime Manager created!
    FrameProcessorBindings: Installing Frame Processor plugins...
    FrameProcessorBindings: Installing Frame Processor plugin "__scanCodes"...
    FrameProcessorBindings: Installing Frame Processor plugin "__labelImage"...
    FrameProcessorBindings: Frame Processor plugins installed!
    FrameProcessorBindings: Installing Frame Processor Bindings for Bridge...
    FrameProcessorBindings: Installing global functions...
    FrameProcessorBindings: Finished installing bindings.
    [javascript] Running "TitrePrepayesApp" with {"rootTag":1,"initialProps":{}}
    [native] [GESTURE HANDLER] Initialize gesture handler for root view <RCTRootContentView: 0x104e19640; reactTag: 1; frame = (0 0; 768 1024); gestureRecognizers = <NSArray: 0x282a4a220>; layer = <CALayer: 0x28243d5e0>>
    [MC] System group container for systemgroup.com.apple.configurationprofiles path is /private/var/containers/Shared/SystemGroup/systemgroup.com.apple.configurationprofiles
    [MC] Reading from public effective user settings.
    [Common] _BSMachError: port b003; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"
    [javascript] 'Frameporcccc', [Function]
    FrameProcessorBindings: Setting new frame processor...
    FrameProcessorBindings: Adapting Shareable value from function (conversion to worklet)...
    FrameProcessorBindings: Successfully created worklet!
    FrameProcessorBindings: Converting worklet to Objective-C callback...
    FrameProcessorBindings: Frame processor set!
    [javascript] Frame Processor threw an error: Value is undefined, expected an Object
    [javascript] Frame Processor threw an error: Value is undefined, expected an Object
    [javascript] Frame Processor threw an error: Value is undefined, expected an Object
    

    Device

    iPad mini 2 on iOS 12.5.5

    VisionCamera Version

    2.11.2 ; 2.11.1 ; 2.9.4

    Additional information

    πŸ› bug 
    opened by HartWoom 34
  • πŸ›  Build Failed in new app created with react-native init

    πŸ› Build Failed in new app created with react-native init

    What were you trying to do?

    run the app on ios simulator/device after installing react-native-vision-camera

    Reproduceable Code

    No response

    What happened instead?

    Build failed with "Cannot convert value of type '[AnyHashable : Any]' to expected argument type '[String : Any]'"

    Relevant log output

    npx react-native info
    info Fetching system and libraries information...
    System:
        OS: macOS 11.6.2
        CPU: (8) arm64 Apple M1
        Memory: 142.83 MB / 8.00 GB
        Shell: 5.8 - /bin/zsh
      Binaries:
        Node: 17.0.1 - /opt/homebrew/bin/node
        Yarn: 1.22.17 - /opt/homebrew/bin/yarn
        npm: 8.1.0 - /opt/homebrew/bin/npm
        Watchman: 2021.11.15.00 - /opt/homebrew/bin/watchman
      Managers:
        CocoaPods: 1.11.2 - /opt/homebrew/bin/pod
      SDKs:
        iOS SDK:
          Platforms: iOS 14.4, DriverKit 20.2, macOS 11.1, tvOS 14.3, watchOS 7.2
        Android SDK:
          API Levels: 29, 31
          Build Tools: 29.0.2, 31.0.0
          System Images: android-29 | Intel x86 Atom_64, android-31 | Google APIs ARM 64 v8a
          Android NDK: Not Found
      IDEs:
        Android Studio: 2020.3 AI-203.7717.56.2031.7784292
        Xcode: 12.4/12D4e - /usr/bin/xcodebuild
      Languages:
        Java: 1.8.0_292 - /usr/bin/javac
      npmPackages:
        @react-native-community/cli: Not Found
        react: 17.0.2 => 17.0.2 
        react-native: 0.66.4 => 0.66.4 
        react-native-macos: Not Found
      npmGlobalPackages:
        *react-native*: Not Found
    

    Device

    iPhone 12 (iOS 14.4)

    VisionCamera Version

    2.11.2

    Additional information

    πŸ› bug 
    opened by firofame 32
  • πŸ› FrameProcessor crash on Android

    πŸ› FrameProcessor crash on Android

    What were you trying to do?

    I was using frameProcessor for object detection.

    Reproduceable Code

    No response

    What happened instead?

    The app crashes sooner or later dependent on how high the frameProcessorFps setting is. This also occurs with imageLabeller and QRScanner plugins/solutions, just not as fast. The higher the setting the faster it crashes. Also a weird side effect is that if the frameProcessorFps is lower than 4 for object detection it doesn't detect anything, higher than 5 and you never get any labels although you will get the boundingBox. With 4 you get labels sometimes. Edit: Ignore the not finding labels correlated to frameProcessorFps, MLKit object detector classifier just has so few categories that you have to point the camera at very specific things.

    Relevant log output

    2021-08-10 19:26:00.959 15302-15413/com.supervaisor.dashcam.staging I/ReactNativeJS: { trackingId: 0,
          labels: [],
          boundingBox: [ 328, 192, 524, 326 ] }
    2021-08-10 19:26:01.046 15302-15413/com.supervaisor.dashcam.staging I/VisionCamera: Setting new Frame Processor...
    2021-08-10 19:26:01.046 15302-15413/com.supervaisor.dashcam.staging D/FrameProcessorRuntime: finding view 539...
    2021-08-10 19:26:01.046 15302-15413/com.supervaisor.dashcam.staging D/FrameProcessorRuntime: found view 539! is null: false
    2021-08-10 19:26:01.047 15302-15413/com.supervaisor.dashcam.staging I/VisionCamera: Found CameraView!
    2021-08-10 19:26:01.047 15302-15413/com.supervaisor.dashcam.staging I/VisionCamera: Adapting Shareable value from function (conversion to worklet)...
    2021-08-10 19:26:01.048 15302-15413/com.supervaisor.dashcam.staging I/VisionCamera: Successfully created worklet!
    2021-08-10 19:26:01.050 15302-15420/com.supervaisor.dashcam.staging I/VisionCamera: Frame Processor set!
    2021-08-10 19:26:01.050 15302-15543/com.supervaisor.dashcam.staging A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x14 in tid 15543 (pool-23-thread-), pid 15302 (dashcam.staging)
    2021-08-10 19:26:01.073 955-960/? E/statsd: Predicate 5980654721335871649 dropping data for dimension key (10)0x2010101->10401[I] (10)0x30000->GCoreFlp[S] 
    2021-08-10 19:26:01.077 955-960/? E/statsd: Predicate 5980654721335871649 dropping data for dimension key (10)0x2010101->10401[I] (10)0x30000->GCoreFlp[S] 
    2021-08-10 19:26:01.096 15302-15413/com.supervaisor.dashcam.staging I/ReactNativeJS: [ 328, 187, 524, 321 ]
    2021-08-10 19:26:01.097 955-960/? E/statsd: Predicate 5980654721335871649 dropping data for dimension key (10)0x2010101->10401[I] (10)0x30000->*location*[S] 
    2021-08-10 19:26:01.106 15302-15413/com.supervaisor.dashcam.staging I/ReactNativeJS: { trackingId: 0,
          labels: [],
          boundingBox: [ 328, 187, 524, 321 ] }
    2021-08-10 19:26:01.113 955-960/? E/statsd: Predicate 5980654721335871649 dropping data for dimension key (10)0x2010101->10401[I] (10)0x30000->*location*[S] 
    2021-08-10 19:26:01.144 15620-15620/? I/crash_dump64: obtaining output fd from tombstoned, type: kDebuggerdTombstone
    2021-08-10 19:26:01.145 945-945/? I/tombstoned: received crash request for pid 15543
    2021-08-10 19:26:01.146 15620-15620/? I/crash_dump64: performing dump of process 15302 (target tid = 15543)
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: Build fingerprint: 'google/sunfish/sunfish:11/RQ3A.210705.001/7380771:user/release-keys'
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: Revision: 'MP1.0'
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: ABI: 'arm64'
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: Timestamp: 2021-08-10 19:26:01+0300
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: pid: 15302, tid: 15543, name: pool-23-thread-  >>> com.supervaisor.dashcam.staging <<<
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: uid: 10401
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x14
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG: Cause: null pointer dereference
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x0  0000000000000000  x1  b40000700a527a80  x2  00000000800001f5  x3  0000000000000001
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x4  0000006dfad998c0  x5  0000006dd56d54fe  x6  000000006854736a  x7  0000000073696854
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x8  4be4b121324c67fc  x9  0000000000000000  x10 b40000700a527a90  x11 0000000000000040
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x12 0000006dfad99a80  x13 0000006dfad99b10  x14 0000006dfad9a338  x15 000000000baa895d
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x16 0000006ded872af8  x17 0000006ded796178  x18 0000006d9f20a000  x19 0000006dfad998c0
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x20 00000000800001f5  x21 b40000700a527a80  x22 b40000700a527a80  x23 0000006e58561fb8
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x24 0000006dfad9d000  x25 b40000700a527a90  x26 0000006e58561fa8  x27 00000000800001f5
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     x28 0000000000000000  x29 0000006dfad99830
    2021-08-10 19:26:01.163 15620-15620/? A/DEBUG:     lr  0000006dedb57d9c  sp  0000006dfad997f0  pc  0000006dedb3982c  pst 0000000000000000
    2021-08-10 19:26:01.226 987-987/? W/SoloThreadMana: type=1400 audit(0.0:1436273): avc: denied { search } for name="camera" dev="dm-12" ino=209 scontext=u:r:hal_camera_default:s0 tcontext=u:object_r:camera_vendor_data_file:s0 tclass=dir permissive=0
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG: backtrace:
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #00 pc 000000000005382c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #01 pc 0000000000071d98  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #02 pc 00000000000726fc  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #03 pc 000000000008cbcc  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #04 pc 000000000008c9a0  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #05 pc 00000000000728b4  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #06 pc 000000000002dfd0  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (facebook::hermes::HermesRuntimeImpl::getProperty(facebook::jsi::Object const&, facebook::jsi::String const&)+128) (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #07 pc 00000000000d11b0  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (facebook::jsi::Object::getProperty(facebook::jsi::Runtime&, facebook::jsi::String const&) const+56) (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #08 pc 00000000000ed070  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (facebook::jsi::Object::getProperty(facebook::jsi::Runtime&, char const*) const+88) (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #09 pc 00000000000e85c4  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #10 pc 00000000000e8538  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #11 pc 00000000000e8474  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #12 pc 00000000000e83d0  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #13 pc 00000000000e7350  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #14 pc 0000000000037288  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (facebook::hermes::HermesRuntimeImpl::HFContext::func(void*, hermes::vm::Runtime*, hermes::vm::NativeArgs)+324) (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #15 pc 000000000005955c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #16 pc 000000000005b1ec  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #17 pc 000000000005a8c8  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #18 pc 0000000000045b6c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #19 pc 000000000002f76c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (facebook::hermes::HermesRuntimeImpl::call(facebook::jsi::Function const&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)+612) (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #20 pc 000000000007ef78  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jsi::Function::callWithThis(facebook::jsi::Runtime&, facebook::jsi::Object const&, facebook::jsi::Value const*, unsigned long) const+120) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #21 pc 00000000000e86bc  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #22 pc 00000000000e8538  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #23 pc 00000000000e8474  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #24 pc 00000000000e83d0  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #25 pc 00000000000e7350  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libreanimated.so (BuildId: 3fb477141bc43d845688e6287afa78528635923c)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #26 pc 0000000000037288  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (facebook::hermes::HermesRuntimeImpl::HFContext::func(void*, hermes::vm::Runtime*, hermes::vm::NativeArgs)+324) (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #27 pc 00000000000455b4  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #28 pc 000000000002f76c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libhermes.so (facebook::hermes::HermesRuntimeImpl::call(facebook::jsi::Function const&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)+612) (BuildId: 6f52702204565e62fc1d0d9a58755bb7a4b543a7)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #29 pc 000000000007ef78  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jsi::Function::callWithThis(facebook::jsi::Runtime&, facebook::jsi::Object const&, facebook::jsi::Value const*, unsigned long) const+120) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #30 pc 000000000007eea8  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jsi::Function::callWithThis(facebook::jsi::Runtime&, facebook::jsi::Object const&, std::initializer_list<facebook::jsi::Value>) const+128) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #31 pc 000000000007dac0  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jsi::Value facebook::jsi::Function::callWithThis<facebook::jsi::Object>(facebook::jsi::Runtime&, facebook::jsi::Object const&, facebook::jsi::Object&&) const+160) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #32 pc 000000000006ee3c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #33 pc 000000000006ed28  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #34 pc 000000000006eca4  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #35 pc 000000000006ec58  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #36 pc 000000000006db30  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #37 pc 0000000000082f94  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #38 pc 0000000000081aec  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (std::__ndk1::function<void (facebook::jni::basic_strong_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*, facebook::jni::LocalReferenceAllocator>)>::operator()(facebook::jni::basic_strong_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*, facebook::jni::LocalReferenceAllocator>) const+48) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #39 pc 00000000000816c4  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (vision::CameraView::frameProcessorCallback(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&)+144) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #40 pc 0000000000082b2c  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jni::detail::MethodWrapper<void (vision::CameraView::*)(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&), &(vision::CameraView::frameProcessorCallback(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&)), vision::CameraView, void, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&>::dispatch(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*>, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&)+212) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #41 pc 0000000000082bb8  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jni::detail::CallWithJniConversions<void (*)(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*>, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&), void, facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&>::call(facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*, facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*, void (*)(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*>, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&))+84) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.351 15620-15620/? A/DEBUG:       #42 pc 00000000000829c8  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jni::detail::FunctionWrapper<void (*)(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*>, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&), facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*, void, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&>::call(_JNIEnv*, _jobject*, facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*, void (*)(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<facebook::jni::HybridClass<vision::CameraView, facebook::jni::detail::BaseHybridClass>::JavaPart, facebook::jni::JObject, void>::_javaobject*>, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&))+56) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #43 pc 0000000000081a40  /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/lib/arm64/libVisionCamera.so (facebook::jni::detail::MethodWrapper<void (vision::CameraView::*)(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&), &(vision::CameraView::frameProcessorCallback(facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&)), vision::CameraView, void, facebook::jni::alias_ref<facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*> const&>::call(_JNIEnv*, _jobject*, facebook::jni::detail::JTypeFor<vision::JImageProxy, facebook::jni::JObject, void>::_javaobject*)+44) (BuildId: 1e6778907e2aef6518e22a27a1f4849673889cbb)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #44 pc 000000000013ced4  /apex/com.android.art/lib64/libart.so (art_quick_generic_jni_trampoline+148) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #45 pc 00000000020ac774  /memfd:jit-cache (deleted) (offset 0x2000000) (com.mrousavy.camera.CameraView.configureSession$lambda-7$lambda-6+212)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #46 pc 00000000001337e8  /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+568) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #47 pc 00000000001a8a94  /apex/com.android.art/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+228) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #48 pc 000000000031831c  /apex/com.android.art/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+376) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #49 pc 000000000030e648  /apex/com.android.art/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+996) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #50 pc 000000000067f49c  /apex/com.android.art/lib64/libart.so (MterpInvokeStatic+548) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #51 pc 000000000012d994  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_static+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #52 pc 000000000000bc28  [anon:dalvik-classes5.dex extracted in memory from /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/base.apk!classes5.dex] (com.mrousavy.camera.CameraView.lambda$cqtIchEZdTZaV3R0UUrDpVbB1Es)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #53 pc 000000000067f740  /apex/com.android.art/lib64/libart.so (MterpInvokeStatic+1224) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #54 pc 000000000012d994  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_static+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #55 pc 0000000000005824  [anon:dalvik-classes5.dex extracted in memory from /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/base.apk!classes5.dex] (com.mrousavy.camera.-$$Lambda$CameraView$cqtIchEZdTZaV3R0UUrDpVbB1Es.analyze+4)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #56 pc 000000000067e21c  /apex/com.android.art/lib64/libart.so (MterpInvokeInterface+1808) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #57 pc 000000000012da14  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_interface+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #58 pc 00000000001e41fe  [anon:dalvik-classes.dex extracted in memory from /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/base.apk] (androidx.camera.core.ImageAnalysis.lambda$setAnalyzer$1$ImageAnalysis+26)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #59 pc 000000000067c7e4  /apex/com.android.art/lib64/libart.so (MterpInvokeVirtual+1520) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #60 pc 000000000012d814  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #61 pc 00000000001de720  [anon:dalvik-classes.dex extracted in memory from /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/base.apk] (androidx.camera.core.-$$Lambda$ImageAnalysis$qO2F3Tn7pfTvGyL-EvT8WWE0F0w.analyze+8)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #62 pc 000000000067e21c  /apex/com.android.art/lib64/libart.so (MterpInvokeInterface+1808) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #63 pc 000000000012da14  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_interface+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #64 pc 00000000001e39a4  [anon:dalvik-classes.dex extracted in memory from /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/base.apk] (androidx.camera.core.ImageAnalysisAbstractAnalyzer.lambda$analyzeImage$0$ImageAnalysisAbstractAnalyzer+64)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #65 pc 000000000067c7e4  /apex/com.android.art/lib64/libart.so (MterpInvokeVirtual+1520) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #66 pc 000000000012d814  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #67 pc 00000000001de770  [anon:dalvik-classes.dex extracted in memory from /data/app/~~jncZlZm09gOrqS8cQluWdw==/com.supervaisor.dashcam.staging-x-zC2nk2Ym5GXmmkLtQgNA==/base.apk] (androidx.camera.core.-$$Lambda$ImageAnalysisAbstractAnalyzer$g-dcm6aZmGod2IWKPwN4CArIZzI.run+16)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #68 pc 000000000067e21c  /apex/com.android.art/lib64/libart.so (MterpInvokeInterface+1808) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #69 pc 000000000012da14  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_interface+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #70 pc 00000000001f9e6e  /apex/com.android.art/javalib/core-oj.jar (java.util.concurrent.ThreadPoolExecutor.runWorker+158)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #71 pc 000000000067c7e4  /apex/com.android.art/lib64/libart.so (MterpInvokeVirtual+1520) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #72 pc 000000000012d814  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #73 pc 00000000001f8c30  /apex/com.android.art/javalib/core-oj.jar (java.util.concurrent.ThreadPoolExecutor$Worker.run+4)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #74 pc 000000000067e21c  /apex/com.android.art/lib64/libart.so (MterpInvokeInterface+1808) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #75 pc 000000000012da14  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_interface+20) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #76 pc 00000000000eb7d0  /apex/com.android.art/javalib/core-oj.jar (java.lang.Thread.run+8)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #77 pc 0000000000305c44  /apex/com.android.art/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) (.llvm.6432830707213048161)+268) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #78 pc 000000000066b24c  /apex/com.android.art/lib64/libart.so (artQuickToInterpreterBridge+780) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #79 pc 000000000013cff8  /apex/com.android.art/lib64/libart.so (art_quick_to_interpreter_bridge+88) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #80 pc 0000000000133564  /apex/com.android.art/lib64/libart.so (art_quick_invoke_stub+548) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #81 pc 00000000001a8a78  /apex/com.android.art/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+200) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #82 pc 0000000000554cbc  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeVirtualOrInterfaceWithJValues<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, jvalue const*)+460) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #83 pc 00000000005a4058  /apex/com.android.art/lib64/libart.so (art::Thread::CreateCallback(void*)+1308) (BuildId: 0183cc6150704cdc371a87b659800e56)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #84 pc 00000000000afd4c  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+64) (BuildId: 49090ae59e6ae37f8beae53c551820ad)
    2021-08-10 19:26:01.352 15620-15620/? A/DEBUG:       #85 pc 0000000000050288  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+64) (BuildId: 49090ae59e6ae37f8beae53c551820ad)
    2021-08-10 19:25:57.852 1753-2127/? I/chatty: uid=1000(system) ConnectivitySer identical 1 line
    2021-08-10 19:26:00.869 1753-2127/? D/ConnectivityService: NetReassign [no changes]
    2021-08-10 19:26:01.724 1753-15624/? W/ActivityTaskManager:   Force finishing activity com.supervaisor.dashcam.staging/com.supervaisor.dashcam.MainActivity
    2021-08-10 19:26:01.724 1753-15625/? I/DropBoxManagerService: add tag=data_app_native_crash isTagEnabled=true flags=0x2
    2021-08-10 19:26:01.326 987-987/? I/chatty: uid=1000(system) [email protected] identical 3 lines
    2021-08-10 19:26:01.360 987-987/? W/SoloThreadMana: type=1400 audit(0.0:1436277): avc: denied { search } for name="camera" dev="dm-12" ino=209 scontext=u:r:hal_camera_default:s0 tcontext=u:object_r:camera_vendor_data_file:s0 tclass=dir permissive=0
    2021-08-10 19:26:01.729 945-945/? E/tombstoned: Tombstone written to: /data/tombstones/tombstone_15
    2021-08-10 19:26:01.735 1753-1889/? I/BootReceiver: Copying /data/tombstones/tombstone_15 to DropBox (SYSTEM_TOMBSTONE)
    2021-08-10 19:26:01.736 1753-1889/? I/DropBoxManagerService: add tag=SYSTEM_TOMBSTONE isTagEnabled=true flags=0x2
    2021-08-10 19:26:01.745 955-960/? E/statsd: Predicate 5980654721335871649 dropping data for dimension key (10)0x2010101->10401[I] (10)0x30000->*launch*[S]
    

    Device

    Pixel 4a

    VisionCamera Version

    2.5.0

    Additional information

    πŸ› bug πŸ€– android 
    opened by Kypsis 30
  • πŸ› Unable to build  in  react native 0.69.1

    πŸ› Unable to build in react native 0.69.1

    What were you trying to do?

    error Failed to install the app. Make sure you have the Android development environment set up:

    FAILURE: Build failed with an exception.

    ..\node_modules\react-native-vision-camera\android\build.gradle' line: 231A problem occurred evaluating project ':react-native-vision-camera'.

    Expected directory '..\node_modules/react-native/android' to contain exactly one file, however, it contains more than one file.

    Reproduceable Code

    No response

    What happened instead?

    unable to build the app

    Relevant log output

    No response

    Device

    android

    VisionCamera Version

    2.13.5

    Additional information

    πŸ› bug 
    opened by rvuyyuru1 28
  • πŸ› Build 'react-native-vision-camera' failed in v0.68.2

    πŸ› Build 'react-native-vision-camera' failed in v0.68.2

    What were you trying to do?

    I get the build error in iOS, and still can't resolve it.

    • "react": "17.0.2"
    • "react-native": "0.68.2"
    • "react-native-vision-camera": "^2.13.5"

    Things I have done

    I deleted my node_modules folder rm -rf package-lock.json && rm -rf yarn.lock && rm -rf node_modules rm -rf ios/Podfile.lock && rm -rf ios/Pods yarn cd ios && pod repo update && pod update && pod install

    ζˆͺεœ– 2022-07-07 11 46 45

    Reproduceable Code

    Undefined symbols for architecture x86_64:
      "typeinfo for reanimated::Scheduler", referenced from:
          typeinfo for vision::VisionCameraScheduler in VisionCameraScheduler.o
      "facebook::react::LongLivedObject::LongLivedObject()", referenced from:
          facebook::react::CallbackWrapper::CallbackWrapper(facebook::jsi::Function&&, facebook::jsi::Runtime&, std::__1::shared_ptr<facebook::react::CallInvoker>) in JSIUtils.o
      "facebook::react::LongLivedObject::~LongLivedObject()", referenced from:
          facebook::react::CallbackWrapper::CallbackWrapper(facebook::jsi::Function&&, facebook::jsi::Runtime&, std::__1::shared_ptr<facebook::react::CallInvoker>) in JSIUtils.o
          facebook::react::CallbackWrapper::~CallbackWrapper() in JSIUtils.o
      "facebook::react::LongLivedObjectCollection::get()", referenced from:
          facebook::react::CallbackWrapper::createWeak(facebook::jsi::Function&&, facebook::jsi::Runtime&, std::__1::shared_ptr<facebook::react::CallInvoker>) in JSIUtils.o
      "typeinfo for facebook::react::LongLivedObject", referenced from:
          typeinfo for facebook::react::CallbackWrapper in JSIUtils.o
      "facebook::react::LongLivedObjectCollection::add(std::__1::shared_ptr<facebook::react::LongLivedObject>) const", referenced from:
          facebook::react::CallbackWrapper::createWeak(facebook::jsi::Function&&, facebook::jsi::Runtime&, std::__1::shared_ptr<facebook::react::CallInvoker>) in JSIUtils.o
      "facebook::jsi::detail::throwJSError(facebook::jsi::Runtime&, char const*)", referenced from:
          std::__1::shared_ptr<facebook::jsi::HostObject> facebook::jsi::Object::asHostObject<facebook::jsi::HostObject>(facebook::jsi::Runtime&) const in JSIUtils.o
      "vtable for reanimated::Scheduler", referenced from:
          reanimated::Scheduler::Scheduler() in VisionCameraScheduler.o
          reanimated::Scheduler::~Scheduler() in VisionCameraScheduler.o
      NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
      "facebook::jsi::Object::getPropertyAsObject(facebook::jsi::Runtime&, char const*) const", referenced from:
          ___43+[JSConsoleHelper getLogFunctionForBridge:]_block_invoke_2 in JSConsoleHelper.o
      "vtable for facebook::jsi::HostObject", referenced from:
          facebook::jsi::HostObject::HostObject() in FrameProcessorUtils.o
      NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
      "typeinfo for facebook::jsi::HostObject", referenced from:
          typeinfo for FrameHostObject in FrameHostObject.o
          convertJSIValueToObjCObject(facebook::jsi::Runtime&, facebook::jsi::Value const&, std::__1::shared_ptr<facebook::react::CallInvoker>) in JSIUtils.o
      "typeinfo for facebook::jsi::JSError", referenced from:
          FrameHostObject::assertIsFrameStrong(facebook::jsi::Runtime&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) in FrameHostObject.o
          FrameHostObject::get(facebook::jsi::Runtime&, facebook::jsi::PropNameID const&)::$_1::operator()(facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long) const in FrameHostObject.o
          GCC_except_table6 in FrameProcessorUtils.o
          GCC_except_table3 in JSConsoleHelper.o
      "facebook::jsi::HostObject::set(facebook::jsi::Runtime&, facebook::jsi::PropNameID const&, facebook::jsi::Value const&)", referenced from:
          vtable for FrameHostObject in FrameHostObject.o
      "facebook::jsi::HostObject::~HostObject()", referenced from:
          FrameHostObject::~FrameHostObject() in FrameHostObject.o
      "facebook::jsi::JSError::~JSError()", referenced from:
          FrameHostObject::assertIsFrameStrong(facebook::jsi::Runtime&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) in FrameHostObject.o
          FrameHostObject::get(facebook::jsi::Runtime&, facebook::jsi::PropNameID const&)::$_1::operator()(facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long) const in FrameHostObject.o
      "facebook::react::LongLivedObject::allowRelease()", referenced from:
          facebook::react::CallbackWrapper::allowRelease() in JSIUtils.o
      "facebook::jsi::JSError::JSError(facebook::jsi::Runtime&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)", referenced from:
          facebook::jsi::JSError::JSError(facebook::jsi::Runtime&, char const*) in FrameHostObject.o
      "facebook::react::LongLivedObjectCollection::remove(facebook::react::LongLivedObject const*) const", referenced from:
          facebook::react::CallbackWrapper::allowRelease() in JSIUtils.o
      "facebook::jsi::Value::Value(facebook::jsi::Value&&)", referenced from:
          facebook::jsi::Value::operator=(facebook::jsi::Value&&) in JSIUtils.o
      "facebook::jsi::Object::getPropertyAsFunction(facebook::jsi::Runtime&, char const*) const", referenced from:
          ___43+[JSConsoleHelper getLogFunctionForBridge:]_block_invoke_2 in JSConsoleHelper.o
      "facebook::jsi::Value::~Value()", referenced from:
          facebook::jsi::Value::Value<facebook::jsi::Function>(facebook::jsi::Function&&) in FrameHostObject.o
          facebook::jsi::Value::Value<facebook::jsi::String>(facebook::jsi::String&&) in FrameHostObject.o
          ____Z42convertJSIFunctionToFrameProcessorCallbackRN8facebook3jsi7RuntimeERKNS0_8FunctionE_block_invoke in FrameProcessorUtils.o
          facebook::jsi::Value facebook::jsi::Function::callWithThis<facebook::jsi::Object>(facebook::jsi::Runtime&, facebook::jsi::Object const&, facebook::jsi::Object&&) const in FrameProcessorUtils.o
          facebook::jsi::Function::callWithThis(facebook::jsi::Runtime&, facebook::jsi::Object const&, facebook::jsi::Value const*, unsigned long) const in FrameProcessorUtils.o
          facebook::jsi::Value::Value(facebook::jsi::Runtime&, facebook::jsi::Object const&) in FrameProcessorUtils.o
          ___43+[JSConsoleHelper getLogFunctionForBridge:]_block_invoke_2 in JSConsoleHelper.o
          ...
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    

    What happened instead?

    Build failed

    Relevant log output

    No response

    Device

    iPhone 8 (iOS 14.3)

    VisionCamera Version

    2.13.5

    Additional information

    πŸ› bug 
    opened by jhongyi 28
  • Updates to fix android builds failing in Expo

    Updates to fix android builds failing in Expo

    What

    This PR applies all the changes from the following comment which did fix the android build issue when using expo custom-dev-client.

    Changes

    • in /android/CMakeLists.txt added ${NODE_MODULES_DIR}/react-native/ReactCommon/jsi/jsi/jsi.cpp in the "add_library" list
    • in /android/CMakeLists.txt removed ${JSI_LIB} from the target_link_libraries list
    • in /android/build.gradle added the following excludes to the packagingOptions "/libreactnativejni.so", "/libfolly_json.so", "/libreanimated.so", "/libjscexecutor.so"
    • in grade.properties changed VisionCamera_compileSdkVersion from 31 to 30

    ⚠️NOTE⚠️ Even with these changes applied the user will need to use the following config plugin (Courtesy of AdamMercy) to get a successful build.

    const { withProjectBuildGradle } = require('@expo/config-plugins')
    
    const setCompileSdkVersion = (buildGradle, sdkVersion) => {
        const regexpCompileSdkVersion = /\bcompileSdkVersion\s*=\s*(\d+)/
        const match = buildGradle.match(regexpCompileSdkVersion)
    
        if (match) {
            const existingVersion = parseInt(match[1], 10)
    
            if (existingVersion < sdkVersion) {
                buildGradle = buildGradle.replace(
                    /\bcompileSdkVersion\s*=\s*\d+/,
                    `compileSdkVersion = ${sdkVersion}`
                )
            } else {
                throw new Error(`minSdkVersion is already >= ${sdkVersion}`)
            }
        }
    
        return buildGradle
    }
    
    module.exports = (config, sdkVersion) => {
        return withProjectBuildGradle(config, (config) => {
            if (config.modResults.language === 'groovy') {
                config.modResults.contents = setCompileSdkVersion(
                    config.modResults.contents,
                    sdkVersion
                )
            } else {
                throw new Error(
                    "Can't set minSdkVersion in the project build.gradle, because it's not groovy"
                )
            }
            return config
        })
    }
    

    Then inside of app.json

    //---------------IN APP.JSON-----------------

    "plugins": [
                "react-native-vision-camera",
                ["./withCompileSdkVersion", 31]
            ]
    

    //---------------IN APP.JSON-----------------

    Tested on

    * Samsung Galaxy Note8
    

    Related issues

    * Closes #546 
    
    opened by haibert 28
  • πŸ› `takePhoto()` doesn't resolve on Android

    πŸ› `takePhoto()` doesn't resolve on Android

    Question

    This is the error I get upon attempting to use takePhoto() on android. This of course is followed by the failure of my promise. I've tried googling the error but I'm not at all finding information a view manager issue (?).

    system/view-not-found: [system/view-not-found] The given view (ID 5079) was not found in the view manager.

    Below is the code that is producing this

    
    import { useCameraDevices, Camera,} from 'react-native-vision-camera' ;
    
    
    
    
    function CameraElement (props) {
    //Ref creation
      const cameraRef = React.useRef();
      const devices = useCameraDevices()
      const device = devices.back
    
      ....
     
    //Handles Taking photo
    const handleCapture = async () => {
      const data = await cameraRef.current.takePhoto({
        enableAutoStabilization: true,
        skipMetadata: true,
        photoCodec: 'jpeg',
        quality: 100,
      });
      console.log(data);
    }
    
      return (
    
          <View style = {{alignItems:'center',}}>
     
                 ....
    
    //THE RELEVANT PART
            <Modal
            animationType="none"
            transparent = {true}
            visible = {isVisCam}>
              <Camera
                ref = {cameraRef}
                style={{width:styles.windowWidth,height:styles.windowHeight*.9}}
                device={device}
                isActive={true}
                photo = {true}
              />
              <View style = {{height:styles.windowHeight*.1, backgroundColor:"white"}}>
                <TouchableOpacity onPress = {handleCapture}><Image source = {require(....)} style = {[styles.iconDim, {alignSelf:"flex-start", justifyContent:"center", margin: 10}]}/></TouchableOpacity>
              </View>
    
            </Modal>
    
    //END OF CAMERA Code
    
          </View>
    
      );
    };
    
    export default CameraElement;
    
    
    

    What I tried

    No response

    VisionCamera Version

    2.4.1

    Additional information

    πŸ› bug πŸ€– android 
    opened by Alih789 28
  • ❓ 2.8.0 > 2.9.1 - Android build error: JSI_LIB not found

    ❓ 2.8.0 > 2.9.1 - Android build error: JSI_LIB not found

    Question

    Hi,

    I'm attempting to upgrade from RNVC 2.8 > 2.9 and hitting a build error:

    Execution failed for task ':react-native-vision-camera:generateJsonModelDebug'.
    > C:\dev\MeshMobile\node_modules\react-native-vision-camera\android\CMakeLists.txt : C/C++ debug|arm64-v8a : CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
      Please set them or make sure they are set and tested correctly in the CMake files:
      JSI_LIB
          linked by target "VisionCamera" in directory C:/dev/MeshMobile/node_modules/react-native-vision-camera/android
    

    Observations:

    • No problems with 2.8.xx.
    • Seems to only affect 2.9.0 and 2.9.1
    • I'm not seeing this error when building the example app
    • Affecting multiple projects (all based on boilerplate provided by npx react-native init ProjectName)

    Repo+branch demonstrating the issue here

    Full Build Log: rnvc2.9.1-build-error.log

    The offending CMakeLists.txt: ~\node_modules\react-native-vision-camera\android\CMakeLists.txt

    I'm stumped. Any thoughts on what I'm doing wrong?

    What I tried

    • Read the install instructions
    • Tested all releases of RNVC from 2.8.0 onwards
    • Enable/disable hermes in build.gradle
    • Set compileSdkVersion to 31
    • Set targetSdkVersion to 31
    • Add android:exported to main activity
    • cd android && gradlew clean
    • Build via npm run android and Android Studio

    VisionCamera Version

    2.9.0 and 2.9.1

    Additional information

    ❓ question 
    opened by ldstein 27
  • How to use takeSnapshot in foreground service ❓

    How to use takeSnapshot in foreground service ❓

    Question

    I'm trying to take pictures in foreground. for example taking pictures when the user is in another app. when we are in the app everything is running fine, But when I close the app while the foreground service is active, the camera stops working and gives this error:

    WARN  Possible Unhandled Promise Rejection (id: 3):
    session/camera-not-ready: [session/camera-not-ready] The Camera is not ready yet! Wait for the onInitialized() callback!
    

    I am using this for foreground service: https://notifee.app/react-native/docs/android/foreground-service and for camera: https://github.com/mrousavy/react-native-vision-camera

    Here is my code:

    const HelloWorldApp = () => {
      const isAppForeground = useIsForeground();
      console.log('In Foreground?: ', isAppForeground);
    
      const cameraRef = useRef(null);
    
      const [finalPath, setPhotoPath] = useState('');
    
      const devices = useCameraDevices();
      const device = devices.front;
    
      useEffect(() => {
        console.log('useEffect');
        notifee.registerForegroundService(() => {
          console.log('registerForegroundService');
          return new Promise(() => {
            setInterval(() => {
              console.log('setInterval');
              const snapShotTaker = async () => {
                const snapshot = await cameraRef.current.takeSnapshot({
                  quality: 20,
                  skipMetadata: true,
                });
                console.log(snapshot);
                setPhotoPath('file://' + snapshot.path);
                console.log(finalPath);
              };
              snapShotTaker();
            }, 2000);
          });
        });
      }, []);
    
      if (device == null) {
        return <ActivityIndicator style={styles.indicator} size="large" />;
      }
    
      async function onDisplayNotification() {
        // Request permissions (required for iOS)
        await notifee.requestPermission();
    
        // Create a channel (required for Android)
        const channelId = await notifee.createChannel({
          id: 'default',
          name: 'Default Channel',
        });
    
        // Display a notification
        await notifee.displayNotification({
          title: 'Foreground service',
          body: 'This notification will exist for the lifetime of the service runner',
          android: {
            channelId,
            asForegroundService: true,
            color: AndroidColor.RED,
            colorized: true,
          },
        });
      }
      const onInitialized = () => {
        console.log('onInitialized');
      };
    
      return (
        <View style={styles.container}>
          <Camera
            ref={cameraRef}
            style={styles.camera}
            device={device}
            isActive={true}
            onInitialized={onInitialized}
          />
          <Image
            source={{uri: finalPath + '?' + new Date()}}
            style={[styles.image]}
          />
    
          <TouchableOpacity style={styles.button} onPress={onDisplayNotification}>
            <Text>Start F Service</Text>
          </TouchableOpacity>
        </View>
      );
    };
    

    VisionCamera Version

    2.15.2

    Additional information

    ❓ question 
    opened by MfaXyz 0
  • πŸ› Unable to use external USB camera

    πŸ› Unable to use external USB camera

    What were you trying to do?

    I wanted to use external USB camera in my android app to take photo.

    const devices = useCameraDevices();
    console.log(devices.external); // returns undefined although my usb camera is connected
    

    Reproduceable Code

    import React, {useCallback, useEffect, useState} from 'react';
    import {Button, View, ToastAndroid} from 'react-native';
    import {
      Camera,
      useCameraDevices,
      CameraRuntimeError,
    } from 'react-native-vision-camera';
    
    const App = () => {
      const devices = useCameraDevices();
      const [cameraPosition, setCameraPosition] = useState<
        'front' | 'back' | 'external'
      >('back');
      const [isCameraInitialized, setIsCameraInitialized] = useState(false);
    
      const device = devices[cameraPosition];
    
      useEffect(() => {
        const requestPermissions = async () => {
          await Camera.requestCameraPermission();
        };
        requestPermissions();
      });
    
      // Camera callbacks
      const onError = useCallback((error: CameraRuntimeError) => {
        console.error(error);
      }, []);
    
      const onInitialized = useCallback(async () => {
        setIsCameraInitialized(true);
      }, []);
    
      return (
        <>
          <View style={{flexDirection: 'row'}}>
            <Button
              title="Use USB Camera"
              onPress={() => {
                setCameraPosition('external');
                ToastAndroid.showWithGravity(
                  'External camera enabled',
                  ToastAndroid.SHORT,
                  ToastAndroid.BOTTOM,
                );
              }}
            />
            <Button
              title="Use back Camera"
              onPress={() => {
                setCameraPosition('back');
                ToastAndroid.showWithGravity(
                  'Back camera enabled',
                  ToastAndroid.SHORT,
                  ToastAndroid.BOTTOM,
                );
              }}
            />
          </View>
          {device != null && (
            <Camera
              device={device}
              isActive={isCameraInitialized}
              onInitialized={onInitialized}
              onError={onError}
              photo={true}
              video={false}
              style={{height: '90%'}}
            />
          )}
        </>
      );
    };
    
    export default App;
    

    What happened instead?

    External USB camera was not detected. Only front and back are available. It doesn't even ask for usb permissions like other apps.

    Vision camera demo

    https://user-images.githubusercontent.com/29520305/210509978-a856a705-a52c-441d-9c7d-82b39332aa8c.mp4

    I can see my usb camera when I use it with other app

    Android USB camera

    https://user-images.githubusercontent.com/29520305/210510747-155ad242-5a80-48f9-8255-fc60a8423b33.mp4

    Relevant log output

    No response

    Device

    All android devices

    VisionCamera Version

    2.15.2

    Additional information

    πŸ› bug 
    opened by rawatnaresh 0
  • πŸ›[android] navigation problem

    πŸ›[android] navigation problem

    What were you trying to do?

    I come back from another screen and try to use the camera again.

    Reproduceable Code

    No response

    What happened instead?

    I see only a black screen. But the camera function works. (If i take a picture on a black screen, the actual screen is taken.)

    Relevant log output

    No response

    Device

    s21+ ultra

    VisionCamera Version

    2.15.2

    Additional information

    πŸ› bug 
    opened by baesumin 1
  • Camera loading speed is slowπŸ›

    Camera loading speed is slowπŸ›

    What were you trying to do?

    When I reach to that particular screen where camera is placed, it takes 2-3 sec to load camera. How I can load fast camera comp.

    Reproduceable Code

    No response

    What happened instead?

    It takes 2-3 sec to load camera.

    Relevant log output

    No response

    Device

    Android

    VisionCamera Version

    2.15.2

    Additional information

    πŸ› bug 
    opened by shakuniyamihir8400 0
  • [android] White screen before camera on πŸ›

    [android] White screen before camera on πŸ›

    What were you trying to do?

    I get a white screen in 3s before camera on.

                {device != null && hasPermission && (
                    <Camera
                      ref={cameraRef}
                      onInitialized={showPopupInstruction}
                      style={StyleSheet.absoluteFill}
                      device={device}
                      isActive
                      orientation="portrait"
                      focusable
                      enableDepthData
                      photo
                    />
                 )}
    

    Reproduceable Code

    No response

    What happened instead?

    I get a white screen in 3s before camera on.

    Relevant log output

    No response

    Device

    android real device

    VisionCamera Version

    2.15.2

    Additional information

    πŸ› bug 
    opened by ChauVV 1
  • πŸ› Android app crashes with java.util.ConcurrentModificationException

    πŸ› Android app crashes with java.util.ConcurrentModificationException

    What were you trying to do?

    We have 51 crash events in firebase console.

    Reproduceable Code

    No response

    What happened instead?

    The app crashes with error: Fatal Exception: java.util.ConcurrentModificationException: at java.util.ArrayList$Itr.next(ArrayList.java:860) at com.mrousavy.camera.frameprocessor.FrameProcessorRuntimeManager.(FrameProcessorRuntimeManager.kt:81) at com.mrousavy.camera.CameraViewModule.initialize$lambda-0(CameraViewModule.kt:66) at com.mrousavy.camera.CameraViewModule.$r8$lambda$YiRnUrObfbO8oH48lnR0UOsrros() at com.mrousavy.camera.CameraViewModule$$ExternalSyntheticLambda2.run(:2) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at java.lang.Thread.run(Thread.java:933)

    Relevant log output

    Fatal Exception: java.util.ConcurrentModificationException:
           at java.util.ArrayList$Itr.next(ArrayList.java:860)
           at com.mrousavy.camera.frameprocessor.FrameProcessorRuntimeManager.<init>(FrameProcessorRuntimeManager.kt:81)
           at com.mrousavy.camera.CameraViewModule.initialize$lambda-0(CameraViewModule.kt:66)
           at com.mrousavy.camera.CameraViewModule.$r8$lambda$YiRnUrObfbO8oH48lnR0UOsrros()
           at com.mrousavy.camera.CameraViewModule$$ExternalSyntheticLambda2.run(:2)
           at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
           at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
           at java.lang.Thread.run(Thread.java:933)
    

    Device

    Android only. Samsung Galaxy A12, Galaxy M31, Galaxy A7 (2018) etc., HONOR X8, OPPO CPH2219, A57

    VisionCamera Version

    2.14.1

    Additional information

    πŸ› bug 
    opened by Maksim-Malikov 0
Releases(v2.15.2)
Owner
Marc Rousavy
they call me ranch cause I be dressing
Marc Rousavy
SharkCardScan is a Credit/Debit Card scanner built using Apple's Vision Framework.

iOS Credit/Debit card scanner, built using Apple's Vision Framework.

Gymshark 23 Nov 16, 2022
A simple macOS app to read code from images, written purely in Swift using Vision Framework.

CodeReader A simple macOS app to read code from images, written purely in Swift using Vision Framework. Usage Drag an image Click the convert button R

Md Ibrahim Hassan 44 Nov 20, 2022
Screen translator for macOS with Apple Vision API and IBM Watson, Google Cloud Translator

Swifty-OCR-Translator Screen translator for macOS with Apple Vision API and IBM Watson, Google Cloud Translator Usage Select Translator Fill in the AP

Kwangmin Bae 21 Sep 13, 2022
Utilizing Apple's Vision Framework to center faces in CGImage.

FaceCrop CGImage extension that utilizes Apple's Vision Framework to detect and center faces. Usage cgImage.faceCrop { [weak self] result in switc

Ancestry.com 40 Nov 24, 2022
Crop faces, inside of your image, with iOS 11 Vision api.

FaceCropper Requirements Xcode 9.0 (beta) or higher. iOS 11.0 (beta) or higher. (It is possible to import this library under the iOS 11. But it won't

Taejun Kim 488 Dec 17, 2022
Picture anonymiser using Vision face recognition

?? Anonymojizer [WIP] Anonymize people in photos by replacing their faces by emojis. How to use it ? Pick a photo from the gallery Choose an emoji The

Kaww 1 Dec 20, 2021
A demo of face recognition SwiftUI app on iOS. Based on Vision, OpenCV, Dlib and ResNet.

iOS-FaceRecognizer A demo of face recognition SwiftUI app on iOS, build for iPad. Based on Vision, OpenCV, Dlib and ResNet. Features Add face image an

js_john 11 Aug 20, 2022
Autocrop - A face-aware crop utility using OSX's Vision framework

autocrop A high-performance face-aware crop utility using OSX's Vision framework

Alex Dong 0 Jan 19, 2022
Simple command-line utility for performing OCR using Apple's Vision framework

ocrit Runs Vision's OCR on input images and outputs corresponding txt files for each image, or writes the recognized results to standard output. USAGE

Guilherme Rambo 61 Nov 23, 2022
Kanvas is an open-source iOS library for adding effects, drawings, text, stickers, and making GIFs from existing media or the camera.

Kanvas Kanvas is an open-source iOS library for adding effects, drawings, text, stickers, and making GIFs from existing media or the camera.

Tumblr 267 Nov 24, 2022
FlaneurImagePicker is an iOS image picker that allows users to pick images from different sources (ex: user's library, user's camera, Instagram...). It's highly customizable.

FlaneurImagePicker is a highly customizable iOS image picker that allows users to pick images from different sources (ex: device's library, device's c

FlaneurApp 17 Feb 2, 2020
FlexibleImage is implemented with the hope that anyone could easily develop an app that provides features such as Camera Filter and Theme.

FlexibleImage is implemented with the hope that anyone could easily develop an app that provides features such as Camera Filter and Theme. When you wr

Jungwon An 815 Dec 30, 2022
Extract opening hours tags from a camera image

OpeningHoursPhoto Extract opening hours tags from a camera image This project is no longer active. The latest development is taking part as part of Go

null 10 May 3, 2021
Swifttty and easy camera framework for iOS.

SwiftttCamera Swifttty and easy camera framework for iOS. View Demo Β· Report Bug Β· Request Feature SwiftttCamera is a wrapper around AVFoundation that

Roger Oba 13 Sep 14, 2022
πŸ“Έ A wrapper for AVCaptureSession - The way easier to use the Camera.

Capturer A wrapper for AVCaptureSession - The way easier to use the Camera. Setting up let captureBody = CaptureBody( configuration: .init { $0.

Muukii 11 Jul 13, 2022
Instant camera hybrid with multiple effects and filters written in Swift.

Kontax Cam Download on the app store! No longer on the app store Kontax Cam is an instant camera built 100% using Swift for iOS. You can take your pho

Kevin Laminto 108 Dec 27, 2022
Simple camera application for iOS that uploads pictures to WebDAV server or Dropbox quickly. Available on the AppStore.

Upupu Simple camera application for iOS that uploads pictures to WebDAV server or Dropbox quickly. Also available on the AppStore. Features Easy and f

Xcoo 65 Nov 15, 2022
AnylineFaceAuthentication pairs identity document scanning with a real-time liveness check utilizing the iPhone's camera, best suited for authenticating users over the internet.

AnylineFaceAuthentication AnylineFaceAuthentication pairs identity document scanning with a real-time liveness check utilizing the iPhone's camera, be

null 0 Mar 7, 2022
A free, multiplatform SDK for real-time facial motion capture using blendshapes, and rigid head pose in 3D space from any RGB camera, photo, or video.

mocap4face by Facemoji mocap4face by Facemoji is a free, multiplatform SDK for real-time facial motion capture based on Facial Action Coding System or

Facemoji 592 Jan 1, 2023