juliansteenbakker / mobile_scanner

A universal scanner for Flutter based on MLKit. Uses CameraX on Android and AVFoundation on iOS.
BSD 3-Clause "New" or "Revised" License
756 stars 446 forks source link

[bug]: Swift Compiler Error (Xcode): Value of type 'AVCaptureDevice' has no member 'automaticallyAdjustsFaceDrivenAutoFocusEnabled' #582

Open lockiechen opened 1 year ago

lockiechen commented 1 year ago
image

can not build ipa because this error

lockiechen commented 1 year ago

version: 3.2.0

sarinkarma commented 1 year ago

Facing the same issue. Any update on this?

faaqi commented 1 year ago

Idk whether its good or not but I replaced this line by:

device.isSmoothAutoFocusEnabled = false

to make it work.

lockiechen commented 1 year ago

Idk whether its good or not but I replaced this line by:

device.isSmoothAutoFocusEnabled = false

to make it work.

@faaqi cloud you show me where to replaced this line?

faaqi commented 1 year ago

@lockiechen

  1. Try to open the project in xcode and build / run it using xcode. You'll see that build failed and errors will appear. Clicking on that error will open this file and specific line where error occurs.

  2. Otherwise , you can find this file as well. I attached the screenshot so that you can view the path.

image
lockiechen commented 1 year ago

i wonder why the bug only occur when i build ipa package

faaqi commented 1 year ago

That needs investigation.

Because when I build IPA after replacing that line. I get this new issue

lockiechen commented 1 year ago

@juliansteenbakker any suggestion?

aoancea commented 1 year ago

I also have the same problem. Are there any updates on it?

aoancea commented 1 year ago

@lockiechen @faaqi any ideas if someone is looking into this ?

faaqi commented 1 year ago

@lockiechen

  1. Try to open the project in xcode and build / run it using xcode. You'll see that build failed and errors will appear. Clicking on that error will open this file and specific line where error occurs.
  2. Otherwise , you can find this file as well. I attached the screenshot so that you can view the path.
  • YourProject
    • ios
    • .symlinks
    • plugins
    • mobils_scanner
    • ios
    • Classes
    • MobileScanner
image

@aoancea , Replacing this line in xcode worked for me. But I was not satisfied with overall performance of the plugin.

I ended up using this plugin

phong016688 commented 1 year ago

Can you quickly fix this problem, or is there a better way to solve this problem. Thank you

afdaldev commented 10 months ago

any update for this issue?

dariobrux commented 9 months ago

Updating MacOs to Ventura 13.5.1 and updating XCode to 14.3.1 they solve this issue