BRScanOptions

Objective-C

@interface BRScanOptions : NSObject

Swift

class BRScanOptions : NSObject

Create an instance of this class to specify the scanning options for a session

Properties

  • If the retailer is known in advance pass in a value from the WFRetailerId enum

    Declaration

    Objective-C

    @property (nonatomic) WFRetailerId retailerId;

    Swift

    var retailerId: WFRetailerId { get set }
  • Whether to return the raw OCR text. If this property is true, -[BRScanResultsDelegate didOutputRawText:] will be called

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL returnRawText;

    Swift

    var returnRawText: Bool { get set }
  • Whether to write the user-confirmed frames to disk. If this property is true, after a scanning session BRScanManager.userFramesFilepaths will contain the local paths of the user frames. You are responsible for deleting these images from disk when you are done with them.

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL storeUserFrames;

    Swift

    var storeUserFrames: Bool { get set }
  • Whether the client uses a Scandit camera independently of the BlinkReceipt SDK. If this is the case, BlinkReceipt will incorporate a fix to an inconsistent camera bug that occurs in this scenario.

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL clientUsesScanditCamera;

    Swift

    var clientUsesScanditCamera: Bool { get set }
  • Whether to store up all the frames that the SDK parsed for inclusion in the debug email after the scan

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL debugMode;

    Swift

    var debugMode: Bool { get set }
  • The compression quality parameter to pass into UIImageJPEGRepresentation for saving user images to disk

    Default: 0.9

    Declaration

    Objective-C

    @property (nonatomic) float jpegCompressionQuality;

    Swift

    var jpegCompressionQuality: Float { get set }
  • This controls when the “Move Closer” message appears. The threshold is a percentage expressed as an integer between 1 and 99. If edges are detected such that the width of the receipt divided by the width of the full image is below this threshold, the “too far” flag will be passed to the client.

    Default: 80

    Declaration

    Objective-C

    @property (nonatomic) NSInteger tooFarThreshold;

    Swift

    var tooFarThreshold: Int { get set }
  • This controls how often edge detection is run on frames returned by the camera. Must be an even integer between 2 and 30. For example, setting this to 8 means edge detection will be run every 8th frame

    Default: 6

    Declaration

    Objective-C

    @property (nonatomic) NSInteger edgesEveryNthFrame;

    Swift

    var edgesEveryNthFrame: Int { get set }
  • Controls whether edge detection is used to make determinations of user’s distance from the receipt

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL detectDistanceWithEdges;

    Swift

    var detectDistanceWithEdges: Bool { get set }
  • The number of consecutive frames above the tooFarThreshold before we stop running edge detection

    Default: 2

    Declaration

    Objective-C

    @property (nonatomic) NSInteger numGoodFramesToStopEdges;

    Swift

    var numGoodFramesToStopEdges: Int { get set }
  • If numGoodFramesToStopEdges is greater than 0, this property allows edge detection to restart after a user confirms a frame

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL restartEdgesAfterUserConfirm;

    Swift

    var restartEdgesAfterUserConfirm: Bool { get set }
  • Whether the SDK should continue edge detection after the first user snapped photo

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL enableEdgesAfterUserPhoto;

    Swift

    var enableEdgesAfterUserPhoto: Bool { get set }
  • Whether the SDK should begin edge detection immediately at the start of the scan session (as opposed to establishing frame quality baselines before starting edge detection)

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL beginEdgesImmediately;

    Swift

    var beginEdgesImmediately: Bool { get set }
  • Whether the SDK should attempt to verify that the user is in fact scanning a receipt from the specified retailer. If this property is true and the SDK detects a different retailer than specified, -[BRCameraViewController didDetectWrongRetailer:withConfidence:] will be triggered, which allows the client to determine if scanning should continue with the new retailer

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL detectWrongRetailer;

    Swift

    var detectWrongRetailer: Bool { get set }
  • Declaration

    Objective-C

    @property (nonatomic, strong) NSString *countryCode;

    Swift

    var countryCode: String! { get set }
  • Whether to enable logo detection

    Default: YES

    Declaration

    Objective-C

    @property (nonatomic) BOOL detectLogo;

    Swift

    var detectLogo: Bool { get set }
  • Whether the client will control the torch manually (should only be used with custom BRCameraViewController subclass). When this is enabled, -[BRCameraViewController didGetLightingCondition:] will be invoked to notify the client of lighting changes

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL manualTorchControl;

    Swift

    var manualTorchControl: Bool { get set }
  • If this property is enabled, the SDK will not perform any on-device frame processing

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL disableOnDeviceProcessing;

    Swift

    var disableOnDeviceProcessing: Bool { get set }
  • If this property is enabled, and the receipt is detected to be a duplicate, BRScanResults.isDuplicate will be set to true. Also checks for fraudulent receipts and sets the BRScanResults.isFraudulent property

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL detectDuplicates;

    Swift

    var detectDuplicates: Bool { get set }
  • If this property is enabled, voided products will be returned with the BRProduct.isVoided property set to YES

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL returnVoidedProducts;

    Swift

    var returnVoidedProducts: Bool { get set }
  • Whether to attempt to validate scan results against specified promotions

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL validatePromotions;

    Swift

    var validatePromotions: Bool { get set }
  • One or more promotion slugs to validate against

    Declaration

    Objective-C

    @property (nonatomic, strong) NSArray *promotionSlugs;

    Swift

    var promotionSlugs: [Any]! { get set }
  • If enabled, the stock camera controller’s UI will adjust based on the user’s text size preference from the Settings or Accessibility screens

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL enableDynamicTextSizing;

    Swift

    var enableDynamicTextSizing: Bool { get set }
  • This property controls how much of the previous frame is visible in the stock controller once a user has touched to add an additional frame. Specified in pixels

    Default: 72

    Declaration

    Objective-C

    @property (nonatomic) NSInteger previousFrameOverlap;

    Swift

    var previousFrameOverlap: Int { get set }
  • If this property is enabled, subproducts will be returned in the BRProduct.subProducts array of the parent product

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL returnSubproducts;

    Swift

    var returnSubproducts: Bool { get set }
  • If enabled, date chip will show whether the date is recognized after scan

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL enableDateChip;

    Swift

    var enableDateChip: Bool { get set }
  • If enabled, total chip will show whether the total is recognized after scan

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL enableTotalChip;

    Swift

    var enableTotalChip: Bool { get set }
  • If enabled, merchant chip will show whether the merchant is recognized after scan

    Default: NO

    Declaration

    Objective-C

    @property (nonatomic) BOOL enableMerchantChip;

    Swift

    var enableMerchantChip: Bool { get set }