Getting Started

Usage of the Biocapture SDK revolves around the BcmScanController class. It implements a customizable View Controller. Minor setup is needed prior to presenting a Scan Controller.

Setup

The Biocapture SDK scan view runs in a View Controller.

It is sufficient to link Biocapture SDK into your Xcode project (Installation) . The Biocapture iOS SDK will not become active until the Scan Controller is initiated.

Your application maintains the Biocapture SDK's global configuration using the BcmGlobalConfig interface. In a typical use case, it is sufficient to set your license key, which is provided to you by Biocapture. The BcmGlobalConfig object can be set in the constructor of the Controller.

There are two other important interfaces, which can be set on the scan Controller:

Use of the Scan Controller

Sample codes with BcmScanController default configuration to start a scan session.

Swift:

class YourViewController: UIViewController {

    var bcmScanController: BcmScanController?

    ...

    func setup {
        // Create BcmScanController instance
        bcmScanController = BcmScanController(
            globalConfig: BcmGlobalConfig(),
            scanConfig: BcmScanConfig(),
            flowDelegate: self) 
            // Note: 'self' must implement the PBcmFlowDelegate
            // see the topic 'Scan Setup'.

        guard let bcmScanController = bcmScanController else { return }

        // Make it full screen
        bcmScanController.modalPresentationStyle = .fullScreen

        // Present Scan Controller instance on your view controller
        self.present(bcmScanController,
            animated: true,
            completion: nil)
    }
}

Scanning

Scanning requires a flow delegate (PBcmFlowDelegate) to return scan data to your application.

Please proceed to the next topic (Scan Setup) for scan customization and PBcmFlowDelegate setup.

See Also

  • BcmScanConfig for configuring underlying Biocapture SDK components, which are related to the scan.
  • PBcmFlowDelegate for additional delegate events.

results matching ""

    No results matching ""