scanbot-web-sdk 8.0.0-beta.1 → 8.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/@types/barcode-scanner-view.d.ts +2 -3
- package/@types/core/{compiled → bridge/compiled}/BarcodeDocumentModel.d.ts +5 -9
- package/@types/core/{compiled → bridge/compiled}/BarcodeDocumentTypes.d.ts +0 -16
- package/@types/core/{compiled → bridge/compiled}/BarcodeScannerTypes.d.ts +7 -83
- package/@types/core/{compiled → bridge/compiled}/BarcodeTypes.d.ts +0 -112
- package/@types/core/{compiled → bridge/compiled}/CheckScannerTypes.d.ts +2 -11
- package/@types/core/{compiled → bridge/compiled}/CreditCardTypes.d.ts +16 -9
- package/@types/core/{compiled → bridge/compiled}/DocumentDataExtractorConfigurationTypes.d.ts +1 -58
- package/@types/core/bridge/compiled/DocumentDataExtractorTypes.d.ts +95 -0
- package/@types/core/{compiled → bridge/compiled}/DocumentQualityAnalyzerTypes.d.ts +2 -2
- package/@types/core/{compiled → bridge/compiled}/DocumentScannerTypes.d.ts +0 -22
- package/@types/core/bridge/compiled/DocumentsModel.d.ts +489 -0
- package/@types/core/bridge/compiled/EuropeanHealthInsuranceCardTypes.d.ts +161 -0
- package/@types/core/{compiled → bridge/compiled}/GenericDocument.d.ts +4 -6
- package/@types/core/bridge/compiled/LicensePlateScannerTypes.d.ts +68 -0
- package/@types/core/{compiled → bridge/compiled}/MedicalCertificateTypes.d.ts +2 -2
- package/@types/core/{compiled → bridge/compiled}/MrzTypes.d.ts +12 -12
- package/@types/core/bridge/compiled/ObjectPoolTypes.d.ts +26 -0
- package/@types/core/{compiled → bridge/compiled}/ParametricFilters.d.ts +14 -1
- package/@types/core/bridge/compiled/SdkLicenseInfo.d.ts +40 -0
- package/@types/core/{compiled → bridge/compiled}/TextPatternScannerTypes.d.ts +17 -4
- package/@types/core/bridge/compiled/utils.d.ts +24 -0
- package/@types/core/bridge/utils.d.ts +0 -8
- package/@types/core/bridge/worker-bridge.d.ts +914 -79
- package/@types/core/worker/ScanbotSDK.Core.d.ts +79 -26
- package/@types/core-types.d.ts +31 -62
- package/@types/cropping-view.d.ts +2 -2
- package/@types/document-scanner-view.d.ts +5 -9
- package/@types/index.d.ts +8 -18
- package/@types/interfaces/i-document-scanner-handle.d.ts +2 -2
- package/@types/model/barcode/barcode-result.d.ts +5 -6
- package/@types/model/configuration/barcode-scanner-view-configuration.d.ts +3 -3
- package/@types/model/configuration/document-scanner-view-configuration.d.ts +2 -2
- package/@types/model/configuration/mrz-scanner-view-configuration.d.ts +2 -2
- package/@types/model/configuration/text-pattern-scanner-view-configuration.d.ts +2 -5
- package/@types/model/configuration/view-finder-scanner-configuration.d.ts +2 -2
- package/@types/model/configuration/vin-scanner-view-configuration.d.ts +2 -5
- package/@types/model/error/license-error.d.ts +1 -1
- package/@types/model/response/cropping-result.d.ts +2 -2
- package/@types/model/response/license-info.d.ts +3 -3
- package/@types/mrz-scanner-view.d.ts +3 -4
- package/@types/scanbot-sdk.d.ts +470 -43
- package/@types/scanner-view.d.ts +1 -3
- package/@types/service/document-data-extractor.d.ts +8 -5
- package/@types/service/document-quality-analyzer.d.ts +11 -0
- package/@types/service/ocr-engine.d.ts +23 -0
- package/@types/service/simple-mrz-recognizer.d.ts +13 -0
- package/@types/service/storage/indexed-db/sb-indexed-db.d.ts +4 -17
- package/@types/service/storage/sb-storage.d.ts +3 -7
- package/@types/service/text-pattern-scanner.d.ts +14 -0
- package/@types/service/vin-scanner.d.ts +16 -0
- package/@types/text-pattern-scanner-view.d.ts +8 -10
- package/@types/ui2/barcode/model/counted-barcodes.d.ts +1 -1
- package/@types/ui2/barcode/views/styled-text.d.ts +1 -0
- package/@types/ui2/common.d.ts +0 -9
- package/@types/ui2/configuration/BarcodeConfigurationTypes.d.ts +1 -1
- package/@types/ui2/configuration/BarcodeDocumentTypes.d.ts +1 -1
- package/@types/ui2/configuration/BarcodeScannerTypes.d.ts +2 -2
- package/@types/ui2/configuration/BarcodeTypes.d.ts +1 -1
- package/@types/ui2/configuration/CommonFieldType.d.ts +1 -1
- package/@types/ui2/configuration/CreditCardTypes.d.ts +2 -6
- package/@types/ui2/configuration/DocumentQualityAnalyzerTypes.d.ts +1 -1
- package/@types/ui2/configuration/DocumentScannerTypes.d.ts +1 -1
- package/@types/ui2/configuration/FrameAccumulationTypes.d.ts +2 -2
- package/@types/ui2/configuration/GenericDocument.d.ts +1 -1
- package/@types/ui2/configuration/Geometry.d.ts +1 -1
- package/@types/ui2/configuration/MrzTypes.d.ts +2 -2
- package/@types/ui2/configuration/ParametricFilters.d.ts +1 -1
- package/@types/ui2/configuration/TextPatternScannerTypes.d.ts +1 -1
- package/@types/ui2/configuration/utils.d.ts +1 -1
- package/@types/ui2/configuration.d.ts +1 -1
- package/@types/ui2/data-scanner/views/mrz-scanner-box.d.ts +1 -1
- package/@types/ui2/document/controller/acknowledgment-screen-controller.d.ts +1 -1
- package/@types/ui2/document/model/document-detection-ui-result.d.ts +3 -3
- package/@types/ui2/document/model/sb-document.d.ts +4 -2
- package/@types/ui2/document/model/sb-page.d.ts +4 -2
- package/@types/ui2/document/model/utils/sb-document-data.d.ts +1 -1
- package/@types/ui2/document/views/camera-screen/bottom-bar.d.ts +2 -2
- package/@types/ui2/document/views/camera-screen/use-document-scanner-view.d.ts +2 -2
- package/@types/utils/dto/MagneticLine.d.ts +1 -3
- package/@types/view/scanbot-camera-view.d.ts +1 -2
- package/@types/worker/worker-bridge.d.ts +884 -42
- package/Libraries.txt +0 -211
- package/README.md +168 -59
- package/bundle/ScanbotSDK.min.js +4 -4
- package/bundle/ScanbotSDK.ui2.min.js +17 -17
- package/bundle/bin/barcode-scanner/ScanbotSDK.Asm-simd-threads.js +1 -1
- package/bundle/bin/barcode-scanner/ScanbotSDK.Asm-simd-threads.wasm +0 -0
- package/bundle/bin/barcode-scanner/ScanbotSDK.Asm-simd.wasm +0 -0
- package/bundle/bin/barcode-scanner/ScanbotSDK.Asm.wasm +0 -0
- package/bundle/bin/barcode-scanner/ScanbotSDK.Core-simd-threads.js +1 -1
- package/bundle/bin/barcode-scanner/ScanbotSDK.Core-simd.js +1 -1
- package/bundle/bin/barcode-scanner/ScanbotSDK.Core.js +1 -1
- package/bundle/bin/complete/ScanbotSDK.Asm-simd-threads.js +1 -1
- package/bundle/bin/complete/ScanbotSDK.Asm-simd-threads.wasm +0 -0
- package/bundle/bin/complete/ScanbotSDK.Asm-simd.wasm +0 -0
- package/bundle/bin/complete/ScanbotSDK.Asm.wasm +0 -0
- package/bundle/bin/complete/ScanbotSDK.Core-simd-threads.js +1 -1
- package/bundle/bin/complete/ScanbotSDK.Core-simd.js +1 -1
- package/bundle/bin/complete/ScanbotSDK.Core.js +1 -1
- package/bundle/bin/document-scanner/ScanbotSDK.Asm-simd-threads.js +1 -1
- package/bundle/bin/document-scanner/ScanbotSDK.Asm-simd-threads.wasm +0 -0
- package/bundle/bin/document-scanner/ScanbotSDK.Asm-simd.wasm +0 -0
- package/bundle/bin/document-scanner/ScanbotSDK.Asm.wasm +0 -0
- package/bundle/bin/document-scanner/ScanbotSDK.Core-simd-threads.js +1 -1
- package/bundle/bin/document-scanner/ScanbotSDK.Core-simd.js +1 -1
- package/bundle/bin/document-scanner/ScanbotSDK.Core.js +1 -1
- package/package.json +2 -2
- package/@types/core/compiled/AcceleratorTypes.d.ts +0 -1
- package/@types/core/compiled/CommonTypes.d.ts +0 -18
- package/@types/core/compiled/DocumentDataExtractorTypes.d.ts +0 -328
- package/@types/core/compiled/DocumentsModel.d.ts +0 -875
- package/@types/core/compiled/LicensingTypes.d.ts +0 -128
- package/@types/core/compiled/WorkerApiEntrypoint.d.ts +0 -30
- package/@types/core/compiled/bridge/BarcodeDocumentParser.d.ts +0 -24
- package/@types/core/compiled/bridge/BarcodeScanner.d.ts +0 -33
- package/@types/core/compiled/bridge/BridgeApiEntrypoint.d.ts +0 -126
- package/@types/core/compiled/bridge/CheckScanner.d.ts +0 -33
- package/@types/core/compiled/bridge/CreditCardScanner.d.ts +0 -39
- package/@types/core/compiled/bridge/DocumentDataExtractor.d.ts +0 -44
- package/@types/core/compiled/bridge/DocumentQualityAnalyzer.d.ts +0 -33
- package/@types/core/compiled/bridge/DocumentScanner.d.ts +0 -51
- package/@types/core/compiled/bridge/ImageProcessor.d.ts +0 -71
- package/@types/core/compiled/bridge/MedicalCertificateScanner.d.ts +0 -34
- package/@types/core/compiled/bridge/MrzScanner.d.ts +0 -61
- package/@types/core/compiled/bridge/OcrEngine.d.ts +0 -31
- package/@types/core/compiled/bridge/TextPatternScanner.d.ts +0 -37
- package/@types/core/compiled/bridge/VinScanner.d.ts +0 -35
- package/@types/core/compiled/bridge/image.d.ts +0 -47
- package/@types/core/compiled/utils.d.ts +0 -47
- package/@types/core/compiled/worker/WorkerBarcodeDocumentParser.d.ts +0 -15
- package/@types/core/compiled/worker/WorkerBarcodeScanner.d.ts +0 -19
- package/@types/core/compiled/worker/WorkerCheckScanner.d.ts +0 -19
- package/@types/core/compiled/worker/WorkerCreditCardScanner.d.ts +0 -20
- package/@types/core/compiled/worker/WorkerDocumentDataExtractor.d.ts +0 -23
- package/@types/core/compiled/worker/WorkerDocumentQualityAnalyzer.d.ts +0 -19
- package/@types/core/compiled/worker/WorkerDocumentScanner.d.ts +0 -25
- package/@types/core/compiled/worker/WorkerImageProcessor.d.ts +0 -32
- package/@types/core/compiled/worker/WorkerMedicalCertificateScanner.d.ts +0 -19
- package/@types/core/compiled/worker/WorkerMrzScanner.d.ts +0 -33
- package/@types/core/compiled/worker/WorkerOcrEngine.d.ts +0 -18
- package/@types/core/compiled/worker/WorkerTextPatternScanner.d.ts +0 -20
- package/@types/core/compiled/worker/WorkerVinScanner.d.ts +0 -20
- package/@types/core/error.d.ts +0 -38
- package/@types/core/worker/workerUtils.d.ts +0 -1
- package/@types/ui2/data-scanner/assets/checkmark-outlined.d.ts +0 -2
- package/@types/utils/license-utils.d.ts +0 -4
- package/@types/worker/worker-error.d.ts +0 -9
- /package/@types/core/{compiled → bridge/compiled}/BarcodeConfigurationTypes.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/CheckDocumentModel.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/CommonFieldType.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/CreditCardDocumentModel.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/FrameAccumulationTypes.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/Geometry.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/ImageTypes.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/OcrTypes.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/PdfConfigurationTypes.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/TiffTypes.d.ts +0 -0
- /package/@types/core/{compiled → bridge/compiled}/VinScannerTypes.d.ts +0 -0
|
@@ -10,7 +10,7 @@ import ScannedImageWithOverlay from "./view/barcode-calculation/scanned-image-wi
|
|
|
10
10
|
import { BarcodeScannerViewConfiguration } from "./model/configuration/barcode-scanner-view-configuration";
|
|
11
11
|
import { Size } from "./utils/dto/Size";
|
|
12
12
|
import { BarcodeItem } from "./core-types";
|
|
13
|
-
import {
|
|
13
|
+
import type { ObjectId } from "./core-types";
|
|
14
14
|
export declare class BarcodeScannerProps extends ScanbotCameraProps {
|
|
15
15
|
}
|
|
16
16
|
export declare class BarcodeScannerState extends ScanbotCameraState {
|
|
@@ -28,7 +28,7 @@ export default class BarcodeScannerView extends ScannerView<BarcodeScannerProps,
|
|
|
28
28
|
popup: BarcodeCalculationPopup | undefined;
|
|
29
29
|
scannedImage: ScannedImageWithOverlay | undefined;
|
|
30
30
|
bottomActionBar: BottomActionBar | undefined;
|
|
31
|
-
|
|
31
|
+
handle: ObjectId<"BarcodeScanner"> | null;
|
|
32
32
|
readonly barcodes: BarcodeItem[];
|
|
33
33
|
private detectionRunning;
|
|
34
34
|
constructor(props: BarcodeScannerProps);
|
|
@@ -42,7 +42,6 @@ export default class BarcodeScannerView extends ScannerView<BarcodeScannerProps,
|
|
|
42
42
|
resumeDetection(): Promise<void>;
|
|
43
43
|
pauseDetection(): void;
|
|
44
44
|
private readonly updateDimensionsCallback;
|
|
45
|
-
onSdkReady(): Promise<void>;
|
|
46
45
|
/**
|
|
47
46
|
* React Overrides
|
|
48
47
|
*/
|
|
@@ -76,17 +76,13 @@ export declare class BoardingPass {
|
|
|
76
76
|
constructor(document: GenericDocument);
|
|
77
77
|
requiredDocumentType(): string;
|
|
78
78
|
/** Electronic Ticket */
|
|
79
|
-
get
|
|
80
|
-
/**
|
|
81
|
-
get
|
|
82
|
-
/** Number
|
|
79
|
+
get electronicTicket(): Field;
|
|
80
|
+
/** Name */
|
|
81
|
+
get name(): Field;
|
|
82
|
+
/** Number Of Legs */
|
|
83
83
|
get numberOfLegs(): Field;
|
|
84
|
-
/** Passenger Name */
|
|
85
|
-
get passengerName(): Field;
|
|
86
84
|
/** Security Data */
|
|
87
|
-
get securityData(): Field
|
|
88
|
-
/** Security Data Type */
|
|
89
|
-
get securityDataType(): Field | undefined;
|
|
85
|
+
get securityData(): Field;
|
|
90
86
|
/** An array of all children of type "Leg". */
|
|
91
87
|
get legs(): BoardingPass.Leg[];
|
|
92
88
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { BarcodeFormat } from "./BarcodeTypes";
|
|
2
2
|
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
3
|
-
import { GenericDocument } from "./GenericDocument";
|
|
4
3
|
/**
|
|
5
4
|
Type of barcode document format used.
|
|
6
5
|
|
|
@@ -59,18 +58,3 @@ export declare namespace BarcodeDocumentFormats {
|
|
|
59
58
|
[key in BarcodeDocumentFormat]: BarcodeFormat[];
|
|
60
59
|
};
|
|
61
60
|
}
|
|
62
|
-
/**
|
|
63
|
-
The result of barcode document parsing.
|
|
64
|
-
*/
|
|
65
|
-
export declare class BarcodeDocumentParserResult extends PartiallyConstructible {
|
|
66
|
-
/**
|
|
67
|
-
True if any document was parsed
|
|
68
|
-
*/
|
|
69
|
-
readonly success: boolean;
|
|
70
|
-
/**
|
|
71
|
-
In case of success, the parsed document
|
|
72
|
-
*/
|
|
73
|
-
readonly parsedDocument: GenericDocument | null;
|
|
74
|
-
/** @param source {@displayType `DeepPartial<BarcodeDocumentParserResult>`} */
|
|
75
|
-
constructor(source?: DeepPartial<BarcodeDocumentParserResult>);
|
|
76
|
-
}
|
|
@@ -3,11 +3,8 @@ import { BarcodeFormatConfigurationBase } from "./BarcodeConfigurationTypes";
|
|
|
3
3
|
import { BarcodeFormat } from "./BarcodeTypes";
|
|
4
4
|
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
5
5
|
import { GenericDocument } from "./GenericDocument";
|
|
6
|
-
import { Image } from "./bridge/image";
|
|
7
6
|
import { Point } from "./utils";
|
|
8
|
-
import {
|
|
9
|
-
import { RangeEncoding } from "./BarcodeTypes";
|
|
10
|
-
import { StructuredAppendInfo } from "./BarcodeTypes";
|
|
7
|
+
import { RawImage } from "./utils";
|
|
11
8
|
/**
|
|
12
9
|
A single barcode found in the input image. Barcodes with the same content but different locations in the image are considered separate barcodes.
|
|
13
10
|
*/
|
|
@@ -17,24 +14,6 @@ export declare class BarcodeItem extends PartiallyConstructible {
|
|
|
17
14
|
*/
|
|
18
15
|
readonly text: string;
|
|
19
16
|
/**
|
|
20
|
-
Raw bytes of barcode contents.
|
|
21
|
-
Some barcode formats are able to encode binary data. If a barcode contains binary data, it's provided as a list of bytes in the rawBytes field.
|
|
22
|
-
Some barcode formats additionally allow pieces of the data within to have different encodings - UTF-8, ASCII, binary, etc.
|
|
23
|
-
The rawBytesEncodings field lists the encoding of each range in the rawBytes array.
|
|
24
|
-
For barcode formats that contain a GS1 message (e.g. GS1 Composite), we recommend to use a GS1Handling and extract the GS1 message from the text.
|
|
25
|
-
*/
|
|
26
|
-
readonly rawBytes: Uint8Array;
|
|
27
|
-
/**
|
|
28
|
-
Encoding information for the rawBytes field. Each element of this list covers some portion of the rawBytes array.
|
|
29
|
-
Taken together, the elements of the list cover the entirety of the rawBytes array without overlap and without holes.
|
|
30
|
-
The elements are ordered in increasing order of the start and end indices.
|
|
31
|
-
*/
|
|
32
|
-
readonly rawBytesEncodings: RangeEncoding[];
|
|
33
|
-
/**
|
|
34
|
-
If this barcode is part of a structured append sequence, this field contains information about the sequence.
|
|
35
|
-
*/
|
|
36
|
-
readonly structuredAppendInfo: StructuredAppendInfo | null;
|
|
37
|
-
/**
|
|
38
17
|
Barcode format.
|
|
39
18
|
@defaultValue "NONE";
|
|
40
19
|
*/
|
|
@@ -56,7 +35,11 @@ export declare class BarcodeItem extends PartiallyConstructible {
|
|
|
56
35
|
A crop from the input image containing the barcode.
|
|
57
36
|
@defaultValue null;
|
|
58
37
|
*/
|
|
59
|
-
readonly sourceImage:
|
|
38
|
+
readonly sourceImage: RawImage | null;
|
|
39
|
+
/**
|
|
40
|
+
Raw bytes of barcode contents. Some formats can contain binary data, which is returned in this field.
|
|
41
|
+
*/
|
|
42
|
+
readonly rawBytes: Uint8Array;
|
|
60
43
|
/**
|
|
61
44
|
If this is a UPC/EAN barcode that has an EAN-2 or EAN-5 extension, this field contains the extension value. Requires the UPC_EAN_EXTENSION format to be enabled in the decoding options.
|
|
62
45
|
*/
|
|
@@ -89,12 +72,6 @@ export declare class BarcodeItem extends PartiallyConstructible {
|
|
|
89
72
|
The parsed known document format (if parsed successfully).
|
|
90
73
|
*/
|
|
91
74
|
readonly extractedDocument: GenericDocument | null;
|
|
92
|
-
/**
|
|
93
|
-
The index of the barcode to uniquely identify it.
|
|
94
|
-
In case of frame accumulation, the index remains the same across frames.
|
|
95
|
-
@defaultValue -1;
|
|
96
|
-
*/
|
|
97
|
-
readonly globalIndex: number;
|
|
98
75
|
/** @param source {@displayType `DeepPartial<BarcodeItem>`} */
|
|
99
76
|
constructor(source?: DeepPartial<BarcodeItem>);
|
|
100
77
|
}
|
|
@@ -110,51 +87,11 @@ The engine mode for barcode scanning.
|
|
|
110
87
|
- `NEXT_GEN_LOW_POWER_FAR_DISTANCE`:
|
|
111
88
|
Similar to NEXT_GEN_LOW_POWER, but optimized for scanning from far distances.
|
|
112
89
|
- `NEXT_GEN_FAR_DISTANCE`:
|
|
113
|
-
Similar to NEXT_GEN,
|
|
90
|
+
Similar to NEXT_GEN, optimized for scanning from far distances.
|
|
114
91
|
*/
|
|
115
92
|
export type BarcodeScannerEngineMode = "LEGACY" | "NEXT_GEN_LOW_POWER" | "NEXT_GEN" | "NEXT_GEN_LOW_POWER_FAR_DISTANCE" | "NEXT_GEN_FAR_DISTANCE";
|
|
116
93
|
export declare const BarcodeScannerEngineModeValues: BarcodeScannerEngineMode[];
|
|
117
94
|
/**
|
|
118
|
-
The method how to display barcodes from previous frames.
|
|
119
|
-
|
|
120
|
-
- `LAST_VISIBLE`:
|
|
121
|
-
The quad of a barcode is simply given as the last quad when it was detected.
|
|
122
|
-
- `INTERPOLATE_BY_CAMERA`:
|
|
123
|
-
The quad of barcode is interpolated by the camera movement. This option is recommended when the camera is moving, but the scanned object is not.
|
|
124
|
-
*/
|
|
125
|
-
export type BarcodeAccumulationMethod = "LAST_VISIBLE" | "INTERPOLATE_BY_CAMERA";
|
|
126
|
-
export declare const BarcodeAccumulationMethodValues: BarcodeAccumulationMethod[];
|
|
127
|
-
/**
|
|
128
|
-
Configuration for how to accumulate results.
|
|
129
|
-
*/
|
|
130
|
-
export declare class BarcodeAccumulationConfiguration extends PartiallyConstructible {
|
|
131
|
-
/**
|
|
132
|
-
In case that ean/upc both with and without extensions are allowed,
|
|
133
|
-
we require confirmations to consider a standalone EAN or UPC (i.e. without extension) as valid.
|
|
134
|
-
@defaultValue 2;
|
|
135
|
-
*/
|
|
136
|
-
minConfirmationsStandaloneEAN: number;
|
|
137
|
-
/**
|
|
138
|
-
Maximum number of accumulated frames to inspect to verify a scan result.
|
|
139
|
-
@defaultValue 5;
|
|
140
|
-
*/
|
|
141
|
-
maximumNumberOfAccumulatedFrames: number;
|
|
142
|
-
/**
|
|
143
|
-
If true, the results from previous frames that are not connected to results on the current frame will be removed.
|
|
144
|
-
This is should be enabled when large camera movements are expected.
|
|
145
|
-
For small camera movements, the option can be disabled.
|
|
146
|
-
@defaultValue true;
|
|
147
|
-
*/
|
|
148
|
-
removeUnconnectedResults: boolean;
|
|
149
|
-
/**
|
|
150
|
-
The method how to display barcodes from previous frames.
|
|
151
|
-
@defaultValue "INTERPOLATE_BY_CAMERA";
|
|
152
|
-
*/
|
|
153
|
-
method: BarcodeAccumulationMethod;
|
|
154
|
-
/** @param source {@displayType `DeepPartial<BarcodeAccumulationConfiguration>`} */
|
|
155
|
-
constructor(source?: DeepPartial<BarcodeAccumulationConfiguration>);
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
95
|
Configuration for the barcode scanner.
|
|
159
96
|
*/
|
|
160
97
|
export declare class BarcodeScannerConfiguration extends PartiallyConstructible {
|
|
@@ -188,24 +125,11 @@ export declare class BarcodeScannerConfiguration extends PartiallyConstructible
|
|
|
188
125
|
*/
|
|
189
126
|
engineMode: BarcodeScannerEngineMode;
|
|
190
127
|
/**
|
|
191
|
-
Configuration to accumulate barcodes across multiple frames in live mode.
|
|
192
|
-
@defaultValue new BarcodeAccumulationConfiguration({});
|
|
193
|
-
*/
|
|
194
|
-
accumulationConfig: BarcodeAccumulationConfiguration;
|
|
195
|
-
/**
|
|
196
128
|
If true, the quads of linear (1D) barcodes will be further refined to more closely match the barcode's outline in the input image.
|
|
197
129
|
This will also produce stabler barcode outlines across frames for use cases such as AR.
|
|
198
130
|
@defaultValue false;
|
|
199
131
|
*/
|
|
200
132
|
optimizedForOverlays: boolean;
|
|
201
|
-
/**
|
|
202
|
-
Scanners typically can produce better results from a single image if they are allowed to spend a longer time analyzing it.
|
|
203
|
-
|
|
204
|
-
On the other hand, scanners can produce even better results if they can analyze multiple images of the same subject and cross-check and combine the results.
|
|
205
|
-
The processing mode tells the scanner whether to optimize for single or multiple images of a subject.
|
|
206
|
-
@defaultValue "AUTO";
|
|
207
|
-
*/
|
|
208
|
-
processingMode: ProcessingMode;
|
|
209
133
|
/** @param source {@displayType `DeepPartial<BarcodeScannerConfiguration>`} */
|
|
210
134
|
constructor(source?: DeepPartial<BarcodeScannerConfiguration>);
|
|
211
135
|
}
|
|
@@ -1,117 +1,5 @@
|
|
|
1
1
|
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
2
2
|
/**
|
|
3
|
-
Enumerates character encodings.
|
|
4
|
-
|
|
5
|
-
- `UNKNOWN`:
|
|
6
|
-
Unknown encoding.
|
|
7
|
-
- `ASCII`:
|
|
8
|
-
ASCII (ISO 646).
|
|
9
|
-
- `ISO_8859_PART1`:
|
|
10
|
-
ISO/IEC 8859 Part 1, a.k.a. Latin-1 Western European.
|
|
11
|
-
- `ISO_8859_PART2`:
|
|
12
|
-
ISO/IEC 8859 Part 2, a.k.a. Latin-2 Central European.
|
|
13
|
-
- `ISO_8859_PART3`:
|
|
14
|
-
ISO/IEC 8859 Part 3, a.k.a. Latin-3 South European.
|
|
15
|
-
- `ISO_8859_PART4`:
|
|
16
|
-
ISO/IEC 8859 Part 4, a.k.a. Latin-4 North European.
|
|
17
|
-
- `ISO_8859_PART5`:
|
|
18
|
-
ISO/IEC 8859 Part 5, a.k.a. Latin/Cyrillic.
|
|
19
|
-
- `ISO_8859_PART6`:
|
|
20
|
-
ISO/IEC 8859 Part 6, a.k.a. Latin/Arabic.
|
|
21
|
-
- `ISO_8859_PART7`:
|
|
22
|
-
ISO/IEC 8859 Part 7, a.k.a. Latin/Greek.
|
|
23
|
-
- `ISO_8859_PART8`:
|
|
24
|
-
ISO/IEC 8859 Part 8, a.k.a. Latin/Hebrew.
|
|
25
|
-
- `ISO_8859_PART9`:
|
|
26
|
-
ISO/IEC 8859 Part 9, a.k.a. Latin-5 Turkish.
|
|
27
|
-
- `ISO_8859_PART10`:
|
|
28
|
-
ISO/IEC 8859 Part 10, a.k.a. Latin-6 Nordic.
|
|
29
|
-
- `ISO_8859_PART11`:
|
|
30
|
-
ISO/IEC 8859 Part 11, a.k.a. Latin/Thai.
|
|
31
|
-
- `ISO_8859_PART13`:
|
|
32
|
-
ISO/IEC 8859 Part 13, a.k.a. Latin-7 Baltic Rim.
|
|
33
|
-
- `ISO_8859_PART14`:
|
|
34
|
-
ISO/IEC 8859 Part 14, a.k.a. Latin-8 Celtic.
|
|
35
|
-
- `ISO_8859_PART15`:
|
|
36
|
-
ISO/IEC 8859 Part 15, a.k.a. Latin-9.
|
|
37
|
-
- `ISO_8859_PART16`:
|
|
38
|
-
ISO/IEC 8859 Part 16, a.k.a. Latin-10 South-Eastern European.
|
|
39
|
-
- `CP_437`:
|
|
40
|
-
CP437 (DOS Latin US).
|
|
41
|
-
- `CP_1250`:
|
|
42
|
-
Windows-1250 (Eastern European).
|
|
43
|
-
- `CP_1251`:
|
|
44
|
-
Windows-1251 (Cyrillic).
|
|
45
|
-
- `CP_1252`:
|
|
46
|
-
Windows-1252 (Western European).
|
|
47
|
-
- `CP_1256`:
|
|
48
|
-
Windows-1256 (Arabic).
|
|
49
|
-
- `SHIFT_JIS`:
|
|
50
|
-
Shift JIS (Japanese).
|
|
51
|
-
- `BIG_5`:
|
|
52
|
-
Big5 (Traditional Chinese).
|
|
53
|
-
- `GB_2312`:
|
|
54
|
-
GB2312 (Simplified Chinese).
|
|
55
|
-
- `GB_18030`:
|
|
56
|
-
GB18030 (Simplified Chinese).
|
|
57
|
-
- `EUC_JP`:
|
|
58
|
-
EUC-JP (Japanese).
|
|
59
|
-
- `EUC_KR`:
|
|
60
|
-
EUC-KR (Korean).
|
|
61
|
-
- `UTF_16_BE`:
|
|
62
|
-
UTF16BE (UTF-16 Big Endian), a.k.a. UnicodeBig.
|
|
63
|
-
- `UTF_8`:
|
|
64
|
-
UTF8 (UTF-8).
|
|
65
|
-
- `UTF_16_LE`:
|
|
66
|
-
UTF16LE (UTF-16 Little Endian).
|
|
67
|
-
- `UTF_32_BE`:
|
|
68
|
-
UTF32BE (UTF-32 Big Endian).
|
|
69
|
-
- `UTF_32_LE`:
|
|
70
|
-
UTF32LE (UTF-32 Little Endian).
|
|
71
|
-
- `BINARY`:
|
|
72
|
-
Binary data.
|
|
73
|
-
*/
|
|
74
|
-
export type CharacterEncoding = "UNKNOWN" | "ASCII" | "ISO_8859_PART1" | "ISO_8859_PART2" | "ISO_8859_PART3" | "ISO_8859_PART4" | "ISO_8859_PART5" | "ISO_8859_PART6" | "ISO_8859_PART7" | "ISO_8859_PART8" | "ISO_8859_PART9" | "ISO_8859_PART10" | "ISO_8859_PART11" | "ISO_8859_PART13" | "ISO_8859_PART14" | "ISO_8859_PART15" | "ISO_8859_PART16" | "CP_437" | "CP_1250" | "CP_1251" | "CP_1252" | "CP_1256" | "SHIFT_JIS" | "BIG_5" | "GB_2312" | "GB_18030" | "EUC_JP" | "EUC_KR" | "UTF_16_BE" | "UTF_8" | "UTF_16_LE" | "UTF_32_BE" | "UTF_32_LE" | "BINARY";
|
|
75
|
-
export declare const CharacterEncodingValues: CharacterEncoding[];
|
|
76
|
-
/**
|
|
77
|
-
A character encoding for a given range of bytes.
|
|
78
|
-
*/
|
|
79
|
-
export declare class RangeEncoding extends PartiallyConstructible {
|
|
80
|
-
/**
|
|
81
|
-
Start index of the range.
|
|
82
|
-
*/
|
|
83
|
-
readonly start: number;
|
|
84
|
-
/**
|
|
85
|
-
End index of the range (inclusive).
|
|
86
|
-
*/
|
|
87
|
-
readonly end: number;
|
|
88
|
-
/**
|
|
89
|
-
Character encoding for the given range.
|
|
90
|
-
*/
|
|
91
|
-
readonly encoding: CharacterEncoding;
|
|
92
|
-
/** @param source {@displayType `DeepPartial<RangeEncoding>`} */
|
|
93
|
-
constructor(source?: DeepPartial<RangeEncoding>);
|
|
94
|
-
}
|
|
95
|
-
/**
|
|
96
|
-
The structured append mode can be used to split a message across multiple barcodes.
|
|
97
|
-
*/
|
|
98
|
-
export declare class StructuredAppendInfo extends PartiallyConstructible {
|
|
99
|
-
/**
|
|
100
|
-
The number of barcodes in the structured append set.
|
|
101
|
-
*/
|
|
102
|
-
readonly count: number;
|
|
103
|
-
/**
|
|
104
|
-
The index of the barcode in the structured append set.
|
|
105
|
-
*/
|
|
106
|
-
readonly index: number;
|
|
107
|
-
/**
|
|
108
|
-
The ID of the structured append set.
|
|
109
|
-
*/
|
|
110
|
-
readonly id: string;
|
|
111
|
-
/** @param source {@displayType `DeepPartial<StructuredAppendInfo>`} */
|
|
112
|
-
constructor(source?: DeepPartial<StructuredAppendInfo>);
|
|
113
|
-
}
|
|
114
|
-
/**
|
|
115
3
|
Enumerates barcode formats.
|
|
116
4
|
|
|
117
5
|
- `NONE`:
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
2
2
|
import { DocumentDetectionResult } from "./DocumentScannerTypes";
|
|
3
3
|
import { GenericDocument } from "./GenericDocument";
|
|
4
|
-
import {
|
|
5
|
-
import { ProcessingMode } from "./CommonTypes";
|
|
4
|
+
import { RawImage } from "./utils";
|
|
6
5
|
/**
|
|
7
6
|
Check document detection and extraction mode.
|
|
8
7
|
|
|
@@ -47,7 +46,7 @@ export declare class CheckScanningResult extends PartiallyConstructible {
|
|
|
47
46
|
/**
|
|
48
47
|
Crop of the check if documentDetectionMode is set to DETECT_AND_CROP_DOCUMENT. Will be non-empty, only if check recognition succeeded.
|
|
49
48
|
*/
|
|
50
|
-
readonly croppedImage:
|
|
49
|
+
readonly croppedImage: RawImage | null;
|
|
51
50
|
/** @param source {@displayType `DeepPartial<CheckScanningResult>`} */
|
|
52
51
|
constructor(source?: DeepPartial<CheckScanningResult>);
|
|
53
52
|
}
|
|
@@ -63,14 +62,6 @@ export declare class CheckScannerConfiguration extends PartiallyConstructible {
|
|
|
63
62
|
@defaultValue "DISABLED";
|
|
64
63
|
*/
|
|
65
64
|
documentDetectionMode: CheckDocumentDetectionMode;
|
|
66
|
-
/**
|
|
67
|
-
Scanners typically can produce better results from a single image if they are allowed to spend a longer time analyzing it.
|
|
68
|
-
|
|
69
|
-
On the other hand, scanners can produce even better results if they can analyze multiple images of the same subject and cross-check and combine the results.
|
|
70
|
-
The processing mode tells the scanner whether to optimize for single or multiple images of a subject.
|
|
71
|
-
@defaultValue "AUTO";
|
|
72
|
-
*/
|
|
73
|
-
processingMode: ProcessingMode;
|
|
74
65
|
/** @param source {@displayType `DeepPartial<CheckScannerConfiguration>`} */
|
|
75
66
|
constructor(source?: DeepPartial<CheckScannerConfiguration>);
|
|
76
67
|
}
|
|
@@ -2,7 +2,6 @@ import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
|
2
2
|
import { DocumentDetectionStatus } from "./DocumentScannerTypes";
|
|
3
3
|
import { GenericDocument } from "./GenericDocument";
|
|
4
4
|
import { Point } from "./utils";
|
|
5
|
-
import { ProcessingMode } from "./CommonTypes";
|
|
6
5
|
import { ResultAccumulationConfiguration } from "./FrameAccumulationTypes";
|
|
7
6
|
/**
|
|
8
7
|
The status of the scanning process.
|
|
@@ -44,6 +43,17 @@ export declare class CreditCardScanningResult extends PartiallyConstructible {
|
|
|
44
43
|
constructor(source?: DeepPartial<CreditCardScanningResult>);
|
|
45
44
|
}
|
|
46
45
|
/**
|
|
46
|
+
The scanning mode.
|
|
47
|
+
|
|
48
|
+
- `LIVE`:
|
|
49
|
+
The scanner will merge all information from multiple frames to provide the best possible result.
|
|
50
|
+
Use this mode when the input is a video or camera stream.
|
|
51
|
+
- `SINGLE_SHOT`:
|
|
52
|
+
The scanner will only use the current frame and will spend additional time to ensure the best possible result. Use this mode when scanning single images, e.g. imported from the gallery.
|
|
53
|
+
*/
|
|
54
|
+
export type CreditCardScanningMode = "LIVE" | "SINGLE_SHOT";
|
|
55
|
+
export declare const CreditCardScanningModeValues: CreditCardScanningMode[];
|
|
56
|
+
/**
|
|
47
57
|
Configuration for the credit card scanner.
|
|
48
58
|
*/
|
|
49
59
|
export declare class CreditCardScannerConfiguration extends PartiallyConstructible {
|
|
@@ -54,6 +64,11 @@ export declare class CreditCardScannerConfiguration extends PartiallyConstructib
|
|
|
54
64
|
*/
|
|
55
65
|
useDocumentDetector: boolean;
|
|
56
66
|
/**
|
|
67
|
+
The scanning mode.
|
|
68
|
+
@defaultValue "LIVE";
|
|
69
|
+
*/
|
|
70
|
+
scanningMode: CreditCardScanningMode;
|
|
71
|
+
/**
|
|
57
72
|
Whether the expiry date is required for a successful scan.
|
|
58
73
|
@defaultValue true;
|
|
59
74
|
*/
|
|
@@ -73,14 +88,6 @@ export declare class CreditCardScannerConfiguration extends PartiallyConstructib
|
|
|
73
88
|
@defaultValue false;
|
|
74
89
|
*/
|
|
75
90
|
returnCreditCardImage: boolean;
|
|
76
|
-
/**
|
|
77
|
-
Scanners typically can produce better results from a single image if they are allowed to spend a longer time analyzing it.
|
|
78
|
-
|
|
79
|
-
On the other hand, scanners can produce even better results if they can analyze multiple images of the same subject and cross-check and combine the results.
|
|
80
|
-
The processing mode tells the scanner whether to optimize for single or multiple images of a subject.
|
|
81
|
-
@defaultValue "AUTO";
|
|
82
|
-
*/
|
|
83
|
-
processingMode: ProcessingMode;
|
|
84
91
|
/** @param source {@displayType `DeepPartial<CreditCardScannerConfiguration>`} */
|
|
85
92
|
constructor(source?: DeepPartial<CreditCardScannerConfiguration>);
|
|
86
93
|
}
|
package/@types/core/{compiled → bridge/compiled}/DocumentDataExtractorConfigurationTypes.d.ts
RENAMED
|
@@ -3,7 +3,7 @@ import { MrzDocumentType } from "./MrzTypes";
|
|
|
3
3
|
/**
|
|
4
4
|
Base class for all generic document configuration elements.
|
|
5
5
|
*/
|
|
6
|
-
export type DocumentDataExtractorConfigurationElement = DateValidationConfiguration |
|
|
6
|
+
export type DocumentDataExtractorConfigurationElement = DateValidationConfiguration | EuropeanHealthInsuranceCardConfiguration | MrzFallbackConfiguration | DocumentDataExtractorCommonConfiguration;
|
|
7
7
|
/** @internal */
|
|
8
8
|
export declare namespace DocumentDataExtractorConfigurationElement {
|
|
9
9
|
/** @internal */
|
|
@@ -36,26 +36,6 @@ export declare class DateValidationConfiguration extends PartiallyConstructible
|
|
|
36
36
|
constructor(source?: DeepPartial<DateValidationConfiguration>);
|
|
37
37
|
}
|
|
38
38
|
/**
|
|
39
|
-
German Address Field validation configuration.
|
|
40
|
-
This configuration does not enable the scanning of any document types by itself.
|
|
41
|
-
Add to recognizer configuration to require German Address validation checks for specific document types.
|
|
42
|
-
*/
|
|
43
|
-
export declare class DeAddressParserConfiguration extends PartiallyConstructible {
|
|
44
|
-
readonly _type: "DeAddressParserConfiguration";
|
|
45
|
-
/**
|
|
46
|
-
List of generic document formats for which German Address validation has to be applied.
|
|
47
|
-
@defaultValue [];
|
|
48
|
-
*/
|
|
49
|
-
documentTypes: string[];
|
|
50
|
-
/**
|
|
51
|
-
binary file with address database.
|
|
52
|
-
@defaultValue "";
|
|
53
|
-
*/
|
|
54
|
-
binaryFileAddressDatabase: string;
|
|
55
|
-
/** @param source {@displayType `DeepPartial<DeAddressParserConfiguration>`} */
|
|
56
|
-
constructor(source?: DeepPartial<DeAddressParserConfiguration>);
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
39
|
European Health Insurance Card (EHIC) issuing country.
|
|
60
40
|
|
|
61
41
|
- `AUSTRIA`:
|
|
@@ -154,43 +134,6 @@ export declare class MrzFallbackConfiguration extends PartiallyConstructible {
|
|
|
154
134
|
constructor(source?: DeepPartial<MrzFallbackConfiguration>);
|
|
155
135
|
}
|
|
156
136
|
/**
|
|
157
|
-
Auto-focus configuration.
|
|
158
|
-
The recognizer will ignore frames that are not focused. This option is enabled by default.
|
|
159
|
-
This configuration has no effect in SINGLE_SHOT mode.
|
|
160
|
-
*/
|
|
161
|
-
export declare class AutoFocusConfiguration extends PartiallyConstructible {
|
|
162
|
-
readonly _type: "AutoFocusConfiguration";
|
|
163
|
-
/**
|
|
164
|
-
Sensitivity threshold for detecting that autofocus is in progress.
|
|
165
|
-
The value should be in the range [0.0, 1.0].
|
|
166
|
-
The lower the value, the more frames might be discarded as not focused.
|
|
167
|
-
The higher the value, the earlier the focus might be considered as focused.
|
|
168
|
-
If set to 0.0, the feature is disabled.
|
|
169
|
-
@defaultValue 0.02;
|
|
170
|
-
*/
|
|
171
|
-
sensitivityThreshold: number;
|
|
172
|
-
/** @param source {@displayType `DeepPartial<AutoFocusConfiguration>`} */
|
|
173
|
-
constructor(source?: DeepPartial<AutoFocusConfiguration>);
|
|
174
|
-
}
|
|
175
|
-
/**
|
|
176
|
-
Glare detection configuration.
|
|
177
|
-
The recognizer will detect whether fields are obstructed by glare. This feature is enabled by default.
|
|
178
|
-
This configuration has no effect in SINGLE_SHOT mode.
|
|
179
|
-
*/
|
|
180
|
-
export declare class GlareDetectionConfiguration extends PartiallyConstructible {
|
|
181
|
-
readonly _type: "GlareDetectionConfiguration";
|
|
182
|
-
/**
|
|
183
|
-
Glare detection threshold.
|
|
184
|
-
The value should be in the range [0.0, 1.0].
|
|
185
|
-
Determines how much glare is acceptable relative to the text size. So 0.5 means that the glare can be up to 50% of the text size.
|
|
186
|
-
If set to 0.0, the feature is disabled.
|
|
187
|
-
@defaultValue 0.5;
|
|
188
|
-
*/
|
|
189
|
-
glareDetectionThreshold: number;
|
|
190
|
-
/** @param source {@displayType `DeepPartial<GlareDetectionConfiguration>`} */
|
|
191
|
-
constructor(source?: DeepPartial<GlareDetectionConfiguration>);
|
|
192
|
-
}
|
|
193
|
-
/**
|
|
194
137
|
Convenience configuration element for enabling the scanning of multiple document types with a common configuration.
|
|
195
138
|
Add to extractor configuration to enable the scanning of multiple document types.
|
|
196
139
|
*/
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
2
|
+
import { DocumentDataExtractorConfigurationElement } from "./DocumentDataExtractorConfigurationTypes";
|
|
3
|
+
import { DocumentDetectionResult } from "./DocumentScannerTypes";
|
|
4
|
+
import { GenericDocument } from "./GenericDocument";
|
|
5
|
+
import { RawImage } from "./utils";
|
|
6
|
+
import { ResultAccumulationConfiguration } from "./FrameAccumulationTypes";
|
|
7
|
+
/**
|
|
8
|
+
The status of the extraction process.
|
|
9
|
+
|
|
10
|
+
- `SUCCESS`:
|
|
11
|
+
The document was extracted successfully.
|
|
12
|
+
- `ERROR_NOTHING_FOUND`:
|
|
13
|
+
No document was detected.
|
|
14
|
+
- `ERROR_BAD_CROP`:
|
|
15
|
+
A document was detected, but it was at an angle/distance that was too large.
|
|
16
|
+
- `ERROR_UNKNOWN_DOCUMENT`:
|
|
17
|
+
A document was detected, but it was not extracted as a supported document.
|
|
18
|
+
- `ERROR_UNACCEPTABLE_DOCUMENT`:
|
|
19
|
+
A document was detected as a supported document, but it was not part of the accepted documents.
|
|
20
|
+
- `INCOMPLETE_VALIDATION`:
|
|
21
|
+
All fields were extracted, but some of them failed validation.
|
|
22
|
+
*/
|
|
23
|
+
export type DocumentDataExtractionStatus = "SUCCESS" | "ERROR_NOTHING_FOUND" | "ERROR_BAD_CROP" | "ERROR_UNKNOWN_DOCUMENT" | "ERROR_UNACCEPTABLE_DOCUMENT" | "INCOMPLETE_VALIDATION";
|
|
24
|
+
export declare const DocumentDataExtractionStatusValues: DocumentDataExtractionStatus[];
|
|
25
|
+
/**
|
|
26
|
+
Contains the result of running the generic document extractor.
|
|
27
|
+
*/
|
|
28
|
+
export declare class DocumentDataExtractionResult extends PartiallyConstructible {
|
|
29
|
+
/**
|
|
30
|
+
The status of the extraction process
|
|
31
|
+
*/
|
|
32
|
+
readonly status: DocumentDataExtractionStatus;
|
|
33
|
+
/**
|
|
34
|
+
The extracted document
|
|
35
|
+
*/
|
|
36
|
+
readonly document: GenericDocument | null;
|
|
37
|
+
/**
|
|
38
|
+
Result of the document detection in the input image.
|
|
39
|
+
*/
|
|
40
|
+
readonly documentDetectionResult: DocumentDetectionResult;
|
|
41
|
+
/**
|
|
42
|
+
Crop of the document if it was detected.
|
|
43
|
+
*/
|
|
44
|
+
readonly croppedImage: RawImage | null;
|
|
45
|
+
/** @param source {@displayType `DeepPartial<DocumentDataExtractionResult>`} */
|
|
46
|
+
constructor(source?: DeepPartial<DocumentDataExtractionResult>);
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
The extraction mode.
|
|
50
|
+
|
|
51
|
+
- `LIVE`:
|
|
52
|
+
The extractor will attempt to accumulate results over multiple frames.
|
|
53
|
+
- `SINGLE_SHOT`:
|
|
54
|
+
The extractor will only use the current frame and will spend additional time to ensure the best possible result.
|
|
55
|
+
*/
|
|
56
|
+
export type DocumentDataExtractionMode = "LIVE" | "SINGLE_SHOT";
|
|
57
|
+
export declare const DocumentDataExtractionModeValues: DocumentDataExtractionMode[];
|
|
58
|
+
/**
|
|
59
|
+
Parameters for the extraction process.
|
|
60
|
+
*/
|
|
61
|
+
export declare class DocumentDataFrameExtractionParameters extends PartiallyConstructible {
|
|
62
|
+
/**
|
|
63
|
+
The extraction mode.
|
|
64
|
+
@defaultValue "LIVE";
|
|
65
|
+
*/
|
|
66
|
+
mode: DocumentDataExtractionMode;
|
|
67
|
+
/** @param source {@displayType `DeepPartial<DocumentDataFrameExtractionParameters>`} */
|
|
68
|
+
constructor(source?: DeepPartial<DocumentDataFrameExtractionParameters>);
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
Configuration for the document data extractor.
|
|
72
|
+
*/
|
|
73
|
+
export declare class DocumentDataExtractorConfiguration extends PartiallyConstructible {
|
|
74
|
+
/**
|
|
75
|
+
Configuration for how to accumulate results.
|
|
76
|
+
@defaultValue new ResultAccumulationConfiguration({});
|
|
77
|
+
*/
|
|
78
|
+
resultAccumulationConfig: ResultAccumulationConfiguration;
|
|
79
|
+
/**
|
|
80
|
+
Normalized names of the fields to exclude from the result.
|
|
81
|
+
@defaultValue [];
|
|
82
|
+
*/
|
|
83
|
+
fieldExcludeList: string[];
|
|
84
|
+
/**
|
|
85
|
+
List of configuration elements for the document data extractor
|
|
86
|
+
*/
|
|
87
|
+
configurations: DocumentDataExtractorConfigurationElement[];
|
|
88
|
+
/**
|
|
89
|
+
If true, crops of the detected documents and fields will be returned in the result.
|
|
90
|
+
@defaultValue false;
|
|
91
|
+
*/
|
|
92
|
+
returnCrops: boolean;
|
|
93
|
+
/** @param source {@displayType `DeepPartial<DocumentDataExtractorConfiguration>`} */
|
|
94
|
+
constructor(source?: DeepPartial<DocumentDataExtractorConfiguration>);
|
|
95
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
2
|
-
import {
|
|
2
|
+
import { RawImage } from "./utils";
|
|
3
3
|
/**
|
|
4
4
|
Result of document quality analysis.
|
|
5
5
|
|
|
@@ -137,7 +137,7 @@ export declare class DocumentQualityAnalyzerResult extends PartiallyConstructibl
|
|
|
137
137
|
Black marks areas of no detected text. Colors represent the quality of detected text,
|
|
138
138
|
with red meaning the lowest quality and yellow and green meaning progressively higher quality.
|
|
139
139
|
*/
|
|
140
|
-
readonly qualityHeatmap:
|
|
140
|
+
readonly qualityHeatmap: RawImage | null;
|
|
141
141
|
/** @param source {@displayType `DeepPartial<DocumentQualityAnalyzerResult>`} */
|
|
142
142
|
constructor(source?: DeepPartial<DocumentQualityAnalyzerResult>);
|
|
143
143
|
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import { AspectRatio } from "./Geometry";
|
|
2
2
|
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
3
|
-
import { Image } from "./bridge/image";
|
|
4
3
|
import { LineSegmentFloat } from "./Geometry";
|
|
5
4
|
import { LineSegmentInt } from "./Geometry";
|
|
6
5
|
import { Point } from "./utils";
|
|
7
|
-
import { ProcessingMode } from "./CommonTypes";
|
|
8
6
|
/**
|
|
9
7
|
Engines for document scanning.
|
|
10
8
|
|
|
@@ -78,11 +76,6 @@ export declare class DocumentScannerConfiguration extends PartiallyConstructible
|
|
|
78
76
|
*/
|
|
79
77
|
engineMode: DocumentScannerEngineMode;
|
|
80
78
|
/**
|
|
81
|
-
In live mode, the document scanner will return only the best document contour. In single-shot mode it will return additional document contours, suitable for use in the cropping screen.
|
|
82
|
-
@defaultValue "AUTO";
|
|
83
|
-
*/
|
|
84
|
-
processingMode: ProcessingMode;
|
|
85
|
-
/**
|
|
86
79
|
Initial parameters for the document scanner.
|
|
87
80
|
@defaultValue new DocumentScannerParameters({});
|
|
88
81
|
*/
|
|
@@ -212,18 +205,3 @@ export declare class DocumentDetectionResult extends PartiallyConstructible {
|
|
|
212
205
|
/** @param source {@displayType `DeepPartial<DocumentDetectionResult>`} */
|
|
213
206
|
constructor(source?: DeepPartial<DocumentDetectionResult>);
|
|
214
207
|
}
|
|
215
|
-
/**
|
|
216
|
-
Result of the document detection followed by cropping of the found document.
|
|
217
|
-
*/
|
|
218
|
-
export declare class DocumentScanningResult extends PartiallyConstructible {
|
|
219
|
-
/**
|
|
220
|
-
Result of the document contour detection
|
|
221
|
-
*/
|
|
222
|
-
readonly detectionResult: DocumentDetectionResult;
|
|
223
|
-
/**
|
|
224
|
-
Cropped document image
|
|
225
|
-
*/
|
|
226
|
-
readonly croppedImage: Image | null;
|
|
227
|
-
/** @param source {@displayType `DeepPartial<DocumentScanningResult>`} */
|
|
228
|
-
constructor(source?: DeepPartial<DocumentScanningResult>);
|
|
229
|
-
}
|