SBSDKUIBarcodeScannerBehaviorConfiguration

@interface SBSDKUIBarcodeScannerBehaviorConfiguration : NSObject

Configuration for the behavior of barcodes.

  • Specifies the way of barcode images generation or disables this generation at all. Use, if you want to receive a full sized image with barcodes. Defaults to SBSDKBarcodeImageGenerationTypeNone.

    Declaration

    Objective-C

    @property (nonatomic) SBSDKBarcodeImageGenerationType barcodeImageGenerationType;

    Swift

    var barcodeImageGenerationType: SBSDKBarcodeImageGenerationType { get set }
  • Whether flash is toggled on or off.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isFlashEnabled) BOOL flashEnabled;

    Swift

    var isFlashEnabled: Bool { get set }
  • Whether scanner screen should make a sound on successful barcode detection.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isSuccessBeepEnabled) BOOL successBeepEnabled;

    Swift

    var isSuccessBeepEnabled: Bool { get set }
  • Time in seconds until the screen is automatically cancelled. Set to 0 to disable automatic cancellation. Defaults to 0 (disabled).

    Declaration

    Objective-C

    @property (nonatomic) NSTimeInterval autoCancelTimeout;

    Swift

    var autoCancelTimeout: TimeInterval { get set }
  • Additional parameters for tweaking the detection of barcodes.

    Declaration

    Objective-C

    @property (nonatomic, strong, nonnull) SBSDKBarcodeAdditionalParameters *additionalParameters;

    Swift

    var additionalParameters: SBSDKBarcodeAdditionalParameters { get set }
  • The range of valid camera zoom factors. Default value is (1.0; 3.0).

    Declaration

    Objective-C

    @property (nonatomic, strong, nonnull) SBSDKZoomRange *cameraZoomRange;

    Swift

    var cameraZoomRange: SBSDKZoomRange { get set }
  • The relative zoom level of the camera relative to zoomRange. The minimum value is 0.0 (zoomed out), the maximum value is 1.0 (zoomed in). The default value is 0.0, zoomed out.

    You can use this value to zoom the camera programmatically but also to set an initial zoom factor.

    Declaration

    Objective-C

    @property (nonatomic) CGFloat cameraZoomFactor;

    Swift

    var cameraZoomFactor: CGFloat { get set }
  • When this property is set to YES, the zoom can be activated by double tapping somewhere in the receivers view. The default value is YES.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isDoubleTapToZoomEnabled) BOOL doubleTapToZoomEnabled;

    Swift

    var isDoubleTapToZoomEnabled: Bool { get set }
  • When this property is set to YES, the zoom can be activated by a pinch gesture somewhere in the receivers view. The default value is YES.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isPinchToZoomEnabled) BOOL pinchToZoomEnabled;

    Swift

    var isPinchToZoomEnabled: Bool { get set }
  • Defines, if zooming in or out should be animated. The default value is YES;

    Declaration

    Objective-C

    @property (nonatomic) BOOL shouldAnimateZooming;

    Swift

    var shouldAnimateZooming: Bool { get set }
  • The barcode detectors engine mode. The default value is SBSDKBarcodeEngineModeNextGen.

    Declaration

    Objective-C

    @property (nonatomic) SBSDKBarcodeEngineMode engineMode;

    Swift

    var engineMode: SBSDKBarcodeEngineMode { get set }
  • Additional filter to reject or accept barcode scanner results. The default value is an instance of SBSDKUIBarcodeFilter.

    Declaration

    Objective-C

    @property (nonatomic, strong, nonnull) SBSDKUIBarcodeFilter *barcodeFilter;

    Swift

    var barcodeFilter: SBSDKUIBarcodeFilter { get set }
  • Disables auto-focus and locks the lens at the specified focus lock lens position. The default value is NO.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isFocusLockEnabled) BOOL focusLockEnabled;

    Swift

    var isFocusLockEnabled: Bool { get set }
  • The position of the lens. Values can be between 0.0f (minimum focusing distance) and 1.0f (maximum focusing distance). The value will be clamped to [0.0f, 1.0f]. The default value is 0.0.

    Declaration

    Objective-C

    @property (nonatomic) CGFloat focusLockPosition;

    Swift

    var focusLockPosition: CGFloat { get set }