Development Guide (Document Capture)
Document Capture
let config = OkayCamConfig(navigationController: nav)OkayCamDoc.start(
okayCamConfig: config,
license: yourLicense,
{ filePaths, error in
// handle
}
)Configuration
let config = OkayCamConfig(navigationController: nav)
config.topLabel.text = "top label text"
config.topLabel.color = .green
config.topLabel.size = 14
config.bottomLabel.text = "bottom label text"
config.bottomLabel.color = .systemPink
config.bottomLabel.size = 20
config.frame.color = .blue
config.frame.size = CGSize(width: 230, height: 100)
config.frame.content = URL(fileURLWithPath: Bundle.main.path(forResource: "image", ofType: "svg")!)
config.showOverlay = false
config.timer.backgroundColor = .magenta
config.timer.textColor = .systemTeal
config.captureBtnColor = .white
config.torchBtnEnabled = false
config.confirmBtnConfig.backgroundColor = .blue
config.confirmBtnConfig.contentColor = .black
config.retakeBtnConfig.backgroundColor = .orange
config.retakeBtnConfig.contentColor = .black
config.captureConfigPair = CaptureConfigPair(
firstPhoto: OkayCamCaptureConfig(
timeOut: 2,
onFlash: false,
onImageQuality: false, // Required for SDK >= 2.0.0
outputPath: myCustomFilePath
),
secondPhoto: OkayCamCaptureConfig(
timeOut: 1,
onFlash: false,
onImageQuality: false, // Required for SDK >= 2.0.0
outputPath: myCustomFilePath
)
)
config.crop = true
config.width = 250
config.imageQuality = 1.0Property
Default
Type
Last updated