MBPFieldByFieldOverlayViewControllerDelegate
Objective-C
@protocol MBPFieldByFieldOverlayViewControllerDelegate <NSObject>
Swift
protocol MBPFieldByFieldOverlayViewControllerDelegate : NSObjectProtocol
Protocol for observing important events with scanning
-
Called when Overlay will close. This can happen if the user pressed close button
Perform here your VC dismiss logic.
Declaration
Objective-C
- (void)fieldByFieldOverlayViewControllerWillClose: (nonnull MBPFieldByFieldOverlayViewController *) fieldByFieldOverlayViewController;
Swift
func field(byFieldOverlayViewControllerWillClose fieldByFieldOverlayViewController: MBPFieldByFieldOverlayViewController)
Parameters
fieldByFieldOverlayViewController
View Controller responsible for scanning
-
Called when Scanning finishes and Overlay will dissapear.
Perform here your VC dismiss logic, as well as result handling
Declaration
Objective-C
- (void)fieldByFieldOverlayViewController: (nonnull MBPFieldByFieldOverlayViewController *) fieldByFieldOverlayViewController didFinishScanningWithElements: (nonnull NSArray<MBPScanElement *> *)scanElements;
Swift
func field(_ fieldByFieldOverlayViewController: MBPFieldByFieldOverlayViewController, didFinishScanningWith scanElements: [MBPScanElement])
Parameters
fieldByFieldOverlayViewController
View Controller responsible for scanning
scanElements
Array of MBPScanElement objects with all scanning results
-
Called when user pressed the help button on the overlay.
Perform logic showing your help instructions here.
Declaration
Objective-C
- (void)fieldByFieldOverlayViewControllerWillPresentHelp: (nonnull MBPFieldByFieldOverlayViewController *) fieldByFieldOverlayViewController;
Swift
optional func field(byFieldOverlayViewControllerWillPresentHelp fieldByFieldOverlayViewController: MBPFieldByFieldOverlayViewController)
Parameters
fieldByFieldOverlayViewController
View Controller responsible for scanning
-
Outputs back each image processed by the SDK.
Declaration
Objective-C
- (void)fieldByFieldOverlayViewController: (nonnull MBPFieldByFieldOverlayViewController *) fieldByFieldOverlayViewController didOutputCurrentImage:(nonnull MBPImage *)currentImage;
Swift
optional func field(_ fieldByFieldOverlayViewController: MBPFieldByFieldOverlayViewController, didOutputCurrentImage currentImage: MBPImage)
Parameters
fieldByFieldOverlayViewController
View Controller responsible for scanning
currentImage
Current image being processed