我使用以下代码在我的
Swift 3.1项目中使用GoogleMobileVision / Barcode检测器:
GMVDetector(ofType: GMVDetectorTypeBarcode,options: nil)
但在日志中显示:
似乎iOS中的GoogleMobileVision是封闭源代码,所以我无法真正看到实现方面发生了什么
关于这里可能发生什么的任何想法?
解决方法
我认为你需要设置一些可选的条形码类型值,如EAN13或QRcode而不是nil.
var detector = GMVDetector() let options:[AnyHashable: Any] = [GMVDetectorBarcodeFormats : GMVDetectorBarcodeFormat.EAN13.rawValue] self.detector = GMVDetector.init(ofType: GMVDetectorTypeBarcode,options: options)
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。