MBCustomOverlayViewController


@interface MBCustomOverlayViewController : MBOverlayViewController

Custom Overlay View Controller is an abstract class for all custom overlay views placed on top View Controller. It’s responsibility is to provide meaningful and useful interface for the user to interact with.

  • Undocumented

    Declaration

    Objective-C

    @property (nonatomic, readonly, strong) MBRecognizerCollection *recognizerCollection

    Swift

    var recognizerCollection: MBRecognizerCollection { get }
  • Undocumented

    Declaration

    Objective-C

    @property (nonatomic, readonly, strong) MBCameraSettings *cameraSettings

    Swift

    var cameraSettings: MBCameraSettings { get }
  • Undocumented

    Declaration

    Objective-C

    @property (nonatomic, strong) MBRecognizerRunnerViewControllerMetadataDelegates *metadataDelegates

    Swift

    var metadataDelegates: MBRecognizerRunnerViewControllerMetadataDelegates { get set }
  • Undocumented

    Declaration

    Objective-C

    @property (nonatomic, weak) id<MBScanningRecognizerRunnerViewControllerDelegate> scanningRecognizerRunnerViewControllerDelegate

    Swift

    weak var scanningRecognizerRunnerViewControllerDelegate: MBScanningRecognizerRunnerViewControllerDelegate? { get set }
  • Undocumented

    Declaration

    Objective-C

    @property (nonatomic, weak) id<MBRecognizerRunnerViewControllerDelegate> recognizerRunnerViewControllerDelegate

    Swift

    weak var recognizerRunnerViewControllerDelegate: MBRecognizerRunnerViewControllerDelegate? { get set }
  • Convenience initializer used for use cases when overlay view controller is instantiated from storyboard. It creates default MBCameraSettings and empty MBRecognizerCollection. To add recognizers after this initializer is used, please use reconfigureRecognizers:.

    Declaration

    Objective-C

    - (nonnull instancetype)init;

    Swift

    convenience init()
  • Undocumented

    Declaration

    Objective-C

    - (instancetype)initWithRecognizerCollection:(MBRecognizerCollection *)recognizerCollection cameraSettings:(MBCameraSettings *)cameraSettings NS_DESIGNATED_INITIALIZER;

    Swift

    init(recognizerCollection: MBRecognizerCollection, cameraSettings: MBCameraSettings)
  • Scanning region Defines a portion of the screen in which the scanning will be performed. Given as a CGRect with unit coordinating system:

    Warning

    Should only be set AFTER RecognizerRunnerViewController has been instantiated with this CustomOverlayViewController, or else it will not have any effect.

    @example CGRectMake(0.2f, 0.5f, 0.4f, 0.3f) defines a portion of the screen which starts at 20% from the left border 50% from the top covers 40% of screen width and 30% of screen heeight

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite)
        CGRect scanningRegion;

    Swift

    var scanningRegion: CGRect { get set }
  • If YES, Overlay View Controller will be autorotated independently of ScanningViewController.

    Default: NO.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite)
        BOOL autorotateOverlay;

    Swift

    var autorotateOverlay: Bool { get set }
  • If YES, default camera overlay will display Status bar. Usually, if camera is displayed inside Navigation View Controler, this is reasonable to set to YES.

    Default: NO.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite) BOOL showStatusBar;

    Swift

    var showStatusBar: Bool { get set }
  • Default: UIInterfaceOrientationMaskPortrait

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite)
        NSUInteger supportedOrientations;

    Swift

    var supportedOrientations: UInt { get set }
  • Reconfigures current recognizer collection to new recognizer collection. Use this method to reconfigure what you wish to scan.

    Declaration

    Objective-C

    - (void)reconfigureRecognizers:
        (nonnull MBRecognizerCollection *)recognizerCollection;

    Swift

    func reconfigureRecognizers(_ recognizerCollection: MBRecognizerCollection)