2

当我尝试使用CIDetector读取 iPhone 或 iPod 上的二维码时,检测器总是返回nil

NSDictionary *detectorOptions = @{@"CIDetectorAccuracy": @"CIDetectorAccuracyHigh"};

CIDetector * detector = [CIDetector  detectorOfType:CIDetectorTypeQRCode context:nil options:detectorOptions];

在 iPad 上运行此代码有效。所有设备都在 iOS 9 上,使用 Xcode 7.0.1

其他检测器工作正常,例如人脸检测成功:

detector = [CIDetector detectorOfType:CIDetectorTypeFace context:nil options:detectorOptions];

是否有额外的设置/库让 QRCode 检测器在 iPhone / iPod 上工作?

4

1 回答 1

0

是的,根据我的测试,它在触摸时不起作用。但在 iPhone 和 iPad 上运行良好。

于 2015-11-12T08:53:01.857 回答