Git Product home page Git Product logo

Comments (10)

Dingenis avatar Dingenis commented on June 6, 2024

I think this might be a duplicate of #2583

from react-native-vision-camera.

lucksp avatar lucksp commented on June 6, 2024

I too am seeing this same issue since updating from version "3.6.4". #2583 is closed, we should reopen or keep this now.

I get an error message, which I do not understand since I am using the useCameraDevice hook:

Camera.onError(device/no-device): [device/no-device] No device was set! Use useCameraDevice(..) or Camera.getAvailableCameraDevices() to select a suitable Camera device.

  const cameraRef = useRef<Component<AnimatedProps<CameraProps>>>(null);
  const device = useCameraDevice('back', {
    physicalDevices: ['ultra-wide-angle-camera', 'wide-angle-camera'],
  });
  const isFocused = useIsFocused();
  const isForeground = useIsForeground();
  const isActive = isFocused && isForeground;

  useEffect(
    function checkPermissions() {
      const status = Camera.getCameraPermissionStatus();
      setCameraPermission(status);
      if (cameraPermission === 'granted') return;
      Camera.requestCameraPermission();
    },
    [cameraPermission]
  );

{!!device && (
            <Reanimated.View>
              <Camera
                animatedProps={animatedProps}
                device={device}
                isActive={isActive}
                photo
                ref={cameraRef}
                style={styles.cameraContainer}
              />
            </Reanimated.View>
      )}

All I did was upgrade my RNVC package to ^3.9.1 since I also updated react native to 0.73.4 as part of the Expo SDK50 update.

from react-native-vision-camera.

lucksp avatar lucksp commented on June 6, 2024

I think this might be a duplicate of #2583

Also a dupe of #2142

from react-native-vision-camera.

mrousavy avatar mrousavy commented on June 6, 2024

Hey! I just released a new V4 beta (v4.0.0-beta.7) where I fixed a bunch of issues! 💪🚀 Can you test that and see if that fixes the issue for you? 😅

yarn add react-native-vision-camera@beta

You might need to increase the compileSdk to the newest Android SDK (34) if you are behind.

from react-native-vision-camera.

j3kin000 avatar j3kin000 commented on June 6, 2024

Hey! I just released a new V4 beta (v4.0.0-beta.7) where I fixed a bunch of issues! 💪🚀 Can you test that and see if that fixes the issue for you? 😅

yarn add react-native-vision-camera@beta

You might need to increase the compileSdk to the newest Android SDK (34) if you are behind.

The stretched issue is fixed but then the onCodeScanned wont be trigger when scanning qr/barcodes

from react-native-vision-camera.

lucksp avatar lucksp commented on June 6, 2024

Anyone here using Expo with Android SDK (34)?

from react-native-vision-camera.

mrousavy avatar mrousavy commented on June 6, 2024

The stretched issue is fixed but then the onCodeScanned wont be trigger when scanning qr/barcodes

I just fixed the Code Scanner issue in the latest V4 beta.

from react-native-vision-camera.

Sfeeen avatar Sfeeen commented on June 6, 2024

Tested with the V4 beta and works normally!

from react-native-vision-camera.

moafandi0 avatar moafandi0 commented on June 6, 2024

Hey! I just released a new V4 beta (v4.0.0-beta.7) where I fixed a bunch of issues! 💪🚀 Can you test that and see if that fixes the issue for you? 😅

yarn add react-native-vision-camera@beta

You might need to increase the compileSdk to the newest Android SDK (34) if you are behind.

I was having a similar issue. The frame width and height were coming out equal when they are not. The update fixed it! I I was also getting 10 FPS on a OnePlus5 device and now I'm getting 17. (I'm using a native Frame Processor). Great job man!! I love this library

from react-native-vision-camera.

mrousavy avatar mrousavy commented on June 6, 2024

Thanks guys, great to hear that V4 now works perfectly! If you appreciate my work, please consider 💖 sponsoring me on GitHub 💖 so I can keep maintaining this library, fixing bugs and building new features! :)

from react-native-vision-camera.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.