1

I'm using Card.io to scan cards inside a custom UIView. The issue I have is that the camera view is taking up the view frame resulting in borders left and right. There's a frame property called cameraPreviewFrame that assigns the window and I think I need to override this property and return it's width and height.

Camera with current borders

Is this possible or is there something else I need to do?

My current code is:

 var cardScanView: CardIOView = {
    let csv = CardIOView()
    csv.guideColor = .blue
    csv.hideCardIOLogo = true
    csv.allowFreelyRotatingCardGuide = false
    csv.backgroundColor = .purple
    return csv
}()

I'm adding this programatically inside a collection view cell and it does work in it's current form. Just the view is off.

Thanks

user7684436
  • 697
  • 14
  • 39
  • Seems like the camera view always uses a 4:3 form factor, making the solution above not possible: http://stackoverflow.com/a/24360576/503750 – José Mar 20 '17 at 11:51

0 Answers0