AnalyzerSettings

data class AnalyzerSettings(val captureSingleSide: Boolean = false, val returnTransformedDocumentImage: Boolean = true, val captureStrategy: CaptureStrategy = CaptureStrategy.Default, @IntRange(from = 150, to = 400) val minimumDocumentDpi: Int = 230, val adjustMinimumDocumentDpi: Boolean = true, @FloatRange(from = 0.0, to = 1.0) val documentFramingMargin: Float = 0.01f, val keepMarginOnTransformedDocumentImage: Boolean = false, val keepDpiOnTransformedDocumentImage: Boolean = false, val lightingThresholds: LightingThresholds = LightingThresholds(), val blurPolicy: BlurPolicy = BlurPolicy.Normal, val glarePolicy: GlarePolicy = GlarePolicy.Normal, @FloatRange(from = 0.0, to = 1.0) val handOcclusionThreshold: Float = 0.05f, val tiltPolicy: TiltPolicy = TiltPolicy.Normal, val enforcedDocumentGroup: EnforcedDocumentGroup? = null) : Parcelable

Settings for the capture analyzer.

Constructors

Link copied to clipboard
constructor(captureSingleSide: Boolean = false, returnTransformedDocumentImage: Boolean = true, captureStrategy: CaptureStrategy = CaptureStrategy.Default, @IntRange(from = 150, to = 400) minimumDocumentDpi: Int = 230, adjustMinimumDocumentDpi: Boolean = true, @FloatRange(from = 0.0, to = 1.0) documentFramingMargin: Float = 0.01f, keepMarginOnTransformedDocumentImage: Boolean = false, keepDpiOnTransformedDocumentImage: Boolean = false, lightingThresholds: LightingThresholds = LightingThresholds(), blurPolicy: BlurPolicy = BlurPolicy.Normal, glarePolicy: GlarePolicy = GlarePolicy.Normal, @FloatRange(from = 0.0, to = 1.0) handOcclusionThreshold: Float = 0.05f, tiltPolicy: TiltPolicy = TiltPolicy.Normal, enforcedDocumentGroup: EnforcedDocumentGroup? = null)

Properties

Link copied to clipboard

Whether to automatically adjust minimum document dpi. If it is enabled, minimum dpi is adjusted to optimal value for provided input resolution to enable capture of all document groups.

Link copied to clipboard

Policy used to discard frames with blurred documents.

Link copied to clipboard

Whether to capture a single side or capture all possible sides of a document with automatic side detection.

Link copied to clipboard

Configures capture strategy used to select the best frame.

Link copied to clipboard

Enables document capture with a margin defined as the percentage of the dimensions of the framed document. Both margin and document are required to be fully visible on camera frame in order to finish capture. Allowed values are from 0 to 1.

Link copied to clipboard

Enforces a specific document group, overriding the analyzer’s document classification. This setting impacts the number of sides scanned to match the enforced group, and the way document image is transformed. If set to null, document group won't be enforced and it will be auto-detected.

Link copied to clipboard

Policy used to discard frames with glare detected on the document.

Link copied to clipboard

Defines percentage of the document area that is allowed to be occluded by hand. Allowed values are from 0 to 1.

Link copied to clipboard

Determines whether to preserve the captured document DPI on transformed document image. If disabled, the document DPI is downscaled to 400 DPI. document with applied margin used during document framing. See documentFramingMargin.

Link copied to clipboard

Whether to return an image of the transformed

Link copied to clipboard

Parameters for lighting estimation.

Link copied to clipboard

Required minimum DPI of the captured document on transformed image. Affects how close the document needs to be to the camera in order to get captured. Allowed values are from 150 to 400 DPI.

Link copied to clipboard

Whether to return an image of a cropped and perspective-corrected document.

Link copied to clipboard

Policy used to detect tilted documents.

Functions

Link copied to clipboard
abstract fun describeContents(): Int
Link copied to clipboard
abstract fun writeToParcel(p0: Parcel, p1: Int)