https://github.com/phonegap/phonegap-plugins/tree/master/iOS/BarcodeScannerの PhoneGap 1.7.0 と Zxing Barcode Scanner を使用して、iPad に Zxing Barcode Scanner を実装しました。ただし、向きは縦のみです。このコードを修正してランドスケープに変更したい
if ([previewLayer isOrientationSupported]) {
[previewLayer setOrientation:AVCaptureVideoOrientationPortrait];
}
そしてこのコードも
if (interfaceOrientation == UIInterfaceOrientationPortrait) return YES;
CDVBarcodeScanner.mm で、Portrait の値を LandscapeRight に変更します。私の問題は、ビデオが全画面表示ではなく、右側に黒い部分があることです。また、横向きモードでも横向きではなく縦向きの場合にのみバーコードをスキャンすると成功します。
ランドスケープモードを完璧にする解決策はありますか?