scanbot-web-sdk 6.0.0-dev.1 → 6.0.0-dev.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 +10 -10
- package/@types/consume-type.d.ts +7 -0
- package/@types/core/bridge/common.d.ts +24 -0
- package/@types/core/bridge/compiled/BarcodeConfigs.d.ts +973 -0
- package/@types/core/bridge/compiled/BarcodeScannerTypes.d.ts +183 -0
- package/@types/core/bridge/compiled/BarcodeTypes.d.ts +183 -0
- package/@types/core/bridge/compiled/CheckRecognizerTypes.d.ts +29 -0
- package/@types/core/bridge/compiled/CommonFieldType.d.ts +59 -0
- package/@types/core/bridge/compiled/DocumentDetectorTypes.d.ts +196 -0
- package/@types/core/bridge/compiled/DocumentQualityAnalyzerTypes.d.ts +105 -0
- package/@types/core/bridge/compiled/EhicTypes.d.ts +218 -0
- package/@types/core/bridge/compiled/FrameUtilities.d.ts +18 -0
- package/@types/core/bridge/compiled/GenericDocument.d.ts +198 -0
- package/@types/core/bridge/compiled/GenericDocumentRecognizerTypes.d.ts +104 -0
- package/@types/core/bridge/compiled/GenericTextLineScannerTypes.d.ts +165 -0
- package/@types/core/bridge/compiled/Geometry.d.ts +49 -0
- package/@types/core/bridge/compiled/ImageProcessorTypes.d.ts +13 -0
- package/@types/core/bridge/compiled/LicensePlateScannerTypes.d.ts +67 -0
- package/@types/core/bridge/compiled/MRZTypes.d.ts +52 -0
- package/@types/core/bridge/compiled/MedicalCertificateTypes.d.ts +306 -0
- package/@types/core/bridge/compiled/OcrElements.d.ts +129 -0
- package/@types/core/bridge/compiled/ParametricFilters.d.ts +186 -0
- package/@types/core/bridge/compiled/PdfConfig.d.ts +197 -0
- package/@types/core/bridge/compiled/TiffTypes.d.ts +183 -0
- package/@types/core/bridge/compiled_schemas_v3/BarcodeConfigs.d.ts +973 -0
- package/@types/core/bridge/compiled_schemas_v3/BarcodeScannerTypes.d.ts +183 -0
- package/@types/core/bridge/compiled_schemas_v3/BarcodeTypes.d.ts +183 -0
- package/@types/core/bridge/compiled_schemas_v3/CheckRecognizerTypes.d.ts +29 -0
- package/@types/core/bridge/compiled_schemas_v3/CommonFieldType.d.ts +59 -0
- package/@types/core/bridge/compiled_schemas_v3/DocumentDetectorTypes.d.ts +196 -0
- package/@types/core/bridge/compiled_schemas_v3/DocumentQualityAnalyzerTypes.d.ts +105 -0
- package/@types/core/bridge/compiled_schemas_v3/EhicTypes.d.ts +218 -0
- package/@types/core/bridge/compiled_schemas_v3/FrameUtilities.d.ts +18 -0
- package/@types/core/bridge/compiled_schemas_v3/GenericDocument.d.ts +198 -0
- package/@types/core/bridge/compiled_schemas_v3/GenericDocumentRecognizerTypes.d.ts +104 -0
- package/@types/core/bridge/compiled_schemas_v3/GenericTextLineScannerTypes.d.ts +165 -0
- package/@types/core/bridge/compiled_schemas_v3/Geometry.d.ts +49 -0
- package/@types/core/bridge/compiled_schemas_v3/ImageProcessorTypes.d.ts +13 -0
- package/@types/core/bridge/compiled_schemas_v3/LicensePlateScannerTypes.d.ts +67 -0
- package/@types/core/bridge/compiled_schemas_v3/MRZTypes.d.ts +52 -0
- package/@types/core/bridge/compiled_schemas_v3/MedicalCertificateTypes.d.ts +306 -0
- package/@types/core/bridge/compiled_schemas_v3/OcrElements.d.ts +129 -0
- package/@types/core/bridge/compiled_schemas_v3/ParametricFilters.d.ts +186 -0
- package/@types/core/bridge/compiled_schemas_v3/PdfConfig.d.ts +197 -0
- package/@types/core/bridge/compiled_schemas_v3/TiffTypes.d.ts +183 -0
- package/@types/core/bridge/utils.d.ts +7 -0
- package/@types/core/bridge/worker-bridge.d.ts +362 -0
- package/@types/core/worker/ScanbotSDK.Core-simd-threads.d.ts +0 -0
- package/@types/core/worker/ScanbotSDK.Core-simd.d.ts +0 -0
- package/@types/core/worker/ScanbotSDK.Core.d.ts +75 -0
- package/@types/core-types.d.ts +23 -0
- package/@types/cropping-view.d.ts +4 -2
- package/@types/document-scanner-view.d.ts +5 -5
- package/@types/generic-document-recognizer-view.d.ts +22 -0
- package/@types/index.d.ts +12 -19
- package/@types/interfaces/i-document-scanner-handle.d.ts +2 -2
- package/@types/interfaces/i-generic-document-recognizer-scanner-handle.d.ts +3 -0
- package/@types/model/barcode/barcode-result.d.ts +6 -8
- package/@types/model/barcode/barcode.d.ts +3 -14
- package/@types/model/configuration/barcode-scanner-configuration.d.ts +12 -8
- package/@types/model/configuration/cropping-view-configuration.d.ts +2 -1
- package/@types/model/configuration/document-scanner-configuration.d.ts +5 -20
- package/@types/model/configuration/generic-document-recognizer-configuration.d.ts +9 -0
- package/@types/model/configuration/initialization-options.d.ts +2 -1
- package/@types/model/configuration/mrz-scanner-configuration.d.ts +4 -3
- package/@types/model/configuration/scanner-configuration.d.ts +1 -0
- package/@types/model/configuration/selection-overlay-configuration.d.ts +2 -2
- package/@types/model/configuration/text-data-scanner-configuration.d.ts +3 -6
- package/@types/model/configuration/view-finder-scanner-configuration.d.ts +3 -2
- package/@types/model/configuration/vin-scanner-configuration.d.ts +2 -1
- package/@types/model/response/cropping-result.d.ts +2 -1
- package/@types/scanbot-sdk.d.ts +208 -29
- package/@types/service/document-quality-analyzer.d.ts +7 -5
- package/@types/service/generic-document-recognizer.d.ts +11 -0
- package/@types/service/ocr-engine.d.ts +8 -5
- package/@types/service/pdf-generator.d.ts +7 -95
- package/@types/service/public-utils.d.ts +1 -1
- package/@types/service/simple-mrz-recognizer.d.ts +5 -5
- package/@types/service/text-data-recognizer.d.ts +5 -4
- package/@types/service/tiff-generator.d.ts +12 -10
- package/@types/ui2/configuration/BarcodeInfoMapping.d.ts +1 -1
- package/@types/ui2/configuration/BarcodeItem.d.ts +4 -28
- package/@types/ui2/configuration/BarcodeRecognizerConfiguration.d.ts +12 -155
- package/@types/ui2/configuration/BarcodeScannerConfiguration.d.ts +2 -18
- package/@types/ui2/configuration/BarcodeScannerTypes.d.ts +6 -0
- package/@types/ui2/configuration/BarcodeTextLocalization.d.ts +0 -60
- package/@types/ui2/configuration/BarcodeTypes.d.ts +1 -0
- package/@types/ui2/configuration/BarcodeUseCase.d.ts +3 -0
- package/@types/ui2/configuration/CameraConfiguration.d.ts +22 -23
- package/@types/ui2/configuration/CameraPermission.d.ts +0 -15
- package/@types/ui2/configuration/Common.d.ts +0 -37
- package/@types/ui2/configuration/FindAndPickScanningModeUseCase.d.ts +2 -2
- package/@types/ui2/configuration/Geometry.d.ts +1 -0
- package/@types/ui2/configuration/MultipleScanningModeUseCase.d.ts +1 -1
- package/@types/ui2/configuration/SingleScanningModeUseCase.d.ts +1 -1
- package/@types/ui2/configuration/TopBarConfiguration.d.ts +0 -16
- package/@types/ui2/configuration/ViewFinderConfiguration.d.ts +6 -3
- package/@types/ui2/configuration.d.ts +1 -1
- package/@types/ui2/controllers/multiple-scanning-mode-controller.d.ts +2 -1
- package/@types/ui2/controllers/single-scanning-mode-controller.d.ts +2 -1
- package/@types/ui2/model/counted-barcodes.d.ts +13 -12
- package/@types/ui2/scanbot-sdk-ui.d.ts +2 -2
- package/@types/ui2/utils/barcode-mapper.d.ts +15 -3
- package/@types/ui2/utils/camera-config.d.ts +2 -2
- package/@types/ui2/utils/styled-input.d.ts +1 -1
- package/@types/ui2/views/action-button/action-button-container.d.ts +2 -0
- package/@types/ui2/views/barcode-scanner.d.ts +4 -3
- package/@types/ui2/views/drawer/subviews/barcode-list-item.d.ts +3 -3
- package/@types/ui2/views/form/dialog-button.d.ts +2 -2
- package/@types/utils/dto/MagneticLine.d.ts +4 -4
- package/@types/utils/dto/Point.d.ts +2 -2
- package/@types/utils/image-utils.d.ts +1 -0
- package/@types/utils/react/usePromise.d.ts +3 -1
- package/@types/utils/utils.d.ts +1 -1
- package/@types/utils/video-stream.d.ts +1 -0
- package/@types/view/action-bar/bottom-action-bar.d.ts +2 -2
- package/@types/view/barcode-calculation/barcode-calculation-popup-list.d.ts +2 -2
- package/@types/view/barcode-calculation/barcode-calculation-popup.d.ts +4 -4
- package/@types/view/barcode-calculation/scanned-image-with-overlay.d.ts +2 -2
- package/@types/view/barcode-polygon/animated-barcode-selection-overlay.d.ts +6 -5
- package/@types/view/barcode-polygon/barcode-overlay.d.ts +3 -3
- package/@types/view/barcode-polygon/barcode-polygon-label.d.ts +2 -2
- package/@types/view/cropping/draggable-base-container.d.ts +8 -2
- package/@types/view/cropping/draggable-handles-component.d.ts +9 -2
- package/@types/view/view-finder.d.ts +1 -0
- package/@types/worker/worker-bridge.d.ts +349 -5
- package/Libraries.txt +307 -174
- package/README.md +3 -3
- package/bundle/ScanbotSDK.min.js +5 -5
- package/bundle/ScanbotSDK.ui2.min.js +108 -161
- package/bundle/ScanbotSDK.ui2.min.js.LICENSE.txt +0 -18
- 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 +4 -3
- package/ui.d.ts +3 -0
- package/ui.js +2 -0
- package/webpack/fileLoader.js +3 -5
- package/@types/core/compiled/ParametricFilters.d.ts +0 -181
- package/@types/core/utils.d.ts +0 -1
- package/@types/core/worker-bridge.d.ts +0 -20
- package/@types/model/barcode/barcode-format.d.ts +0 -1
- package/@types/model/barcode/engine-mode.d.ts +0 -1
- package/@types/model/configuration/document-quality-analyzer-configuration.d.ts +0 -13
- package/@types/model/document/contour-detection-result.d.ts +0 -11
- package/@types/model/document/detection-status.d.ts +0 -11
- package/@types/model/document/document-detection-result.d.ts +0 -8
- package/@types/model/filter-types.d.ts +0 -6
- package/@types/model/generic-text-line-recognizer/text-data-scanner-result.d.ts +0 -6
- package/@types/model/mrz/mrz-result.d.ts +0 -41
- package/@types/model/response/document-quality-analyzer-result.d.ts +0 -8
- package/@types/service/image-processor.d.ts +0 -35
- package/@types/ui2/configuration/BarcodeResult.d.ts +0 -14
- package/@types/utils/networking.d.ts +0 -7
- package/bundle/bin/barcode-scanner/ScanbotSDK.Asm.wasm-webpack-file-loader +0 -0
- package/bundle/bin/complete/ScanbotSDK.Asm-simd-threads.wasm-webpack-file-loader +0 -0
- package/bundle/bin/complete/ScanbotSDK.Asm-simd.wasm-webpack-file-loader +0 -0
- package/bundle/bin/complete/ScanbotSDK.Asm.wasm-webpack-file-loader +0 -0
- package/bundle/bin/document-scanner/ScanbotSDK.Asm.wasm-webpack-file-loader +0 -0
package/ui.d.ts
ADDED
package/ui.js
ADDED
package/webpack/fileLoader.js
CHANGED
|
@@ -2,9 +2,7 @@ require('!!file-loader?name=ScanbotSDK.Core.js!../bundle/bin/complete/ScanbotSDK
|
|
|
2
2
|
require('!!file-loader?name=ScanbotSDK.Core-simd.js!../bundle/bin/complete/ScanbotSDK.Core-simd.js');
|
|
3
3
|
require('!!file-loader?name=ScanbotSDK.Core-simd-threads.js!../bundle/bin/complete/ScanbotSDK.Core-simd-threads.js');
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
require('!!file-loader?esModule=false&name=ScanbotSDK.Asm-simd.wasm!../bundle/bin/complete/ScanbotSDK.Asm-simd.wasm-webpack-file-loader');
|
|
9
|
-
require('!!file-loader?esModule=false&name=ScanbotSDK.Asm-simd-threads.wasm!../bundle/bin/complete/ScanbotSDK.Asm-simd-threads.wasm-webpack-file-loader');
|
|
5
|
+
export const path = require('!!file-loader?esModule=false&name=ScanbotSDK.Asm.wasm!../bundle/bin/complete/ScanbotSDK.Asm.wasm');
|
|
6
|
+
require('!!file-loader?esModule=false&name=ScanbotSDK.Asm-simd.wasm!../bundle/bin/complete/ScanbotSDK.Asm-simd.wasm');
|
|
7
|
+
require('!!file-loader?esModule=false&name=ScanbotSDK.Asm-simd-threads.wasm!../bundle/bin/complete/ScanbotSDK.Asm-simd-threads.wasm');
|
|
10
8
|
require('!!file-loader?esModule=false&name=ScanbotSDK.Asm-simd-threads.js!../bundle/bin/complete/ScanbotSDK.Asm-simd-threads.js');
|
|
@@ -1,181 +0,0 @@
|
|
|
1
|
-
/// Auto-generated. Modification will be overwritten.
|
|
2
|
-
|
|
3
|
-
/** Output mode of binarization filter.*/
|
|
4
|
-
export type OutputMode =
|
|
5
|
-
/** BINARY - Black and white image, suitable for 1-bit compression.*/
|
|
6
|
-
"BINARY" |
|
|
7
|
-
|
|
8
|
-
/** ANTIALIASED - When the source image is a document photo, this mode
|
|
9
|
-
will produce nice, smooth, antialiased text in grayscale, which is typically more readable
|
|
10
|
-
than the text in BINARY mode. Antialiasing requires extra processing,
|
|
11
|
-
which makes this mode slower than BINARY mode.
|
|
12
|
-
*/
|
|
13
|
-
"ANTIALIASED";
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
/** Preset of parameters for custom binarization filter.*/
|
|
17
|
-
export type BinarizationFilterPreset =
|
|
18
|
-
/** Usually performs well if there is no shadow.*/
|
|
19
|
-
"PRESET_1" |
|
|
20
|
-
|
|
21
|
-
/** Usually performs well even if there are shadows.*/
|
|
22
|
-
"PRESET_2" |
|
|
23
|
-
|
|
24
|
-
/** Usually performs well even if there are shadows.*/
|
|
25
|
-
"PRESET_3" |
|
|
26
|
-
|
|
27
|
-
/** Usually performs well even if there are shadows.*/
|
|
28
|
-
"PRESET_4";
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
/** Automatic binarization filter. This filter is a good starting point for most use cases.*/
|
|
33
|
-
export class ScanbotBinarizationFilter {
|
|
34
|
-
|
|
35
|
-
/** Output mode of the filter. BINARY will return a black and white image, GRAYSCALE will return an antialiased grayscale image.*/
|
|
36
|
-
outputMode: OutputMode;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
/** @internal */
|
|
40
|
-
toWireType(): any;
|
|
41
|
-
}
|
|
42
|
-
/** Automatic binarization filter. This filter is a good starting point for most use cases.*/
|
|
43
|
-
export class CustomBinarizationFilter {
|
|
44
|
-
|
|
45
|
-
/** Preset of binarization filter parameters that are found to perform well on different types of documents.*/
|
|
46
|
-
preset: BinarizationFilterPreset;
|
|
47
|
-
|
|
48
|
-
/** Output mode of the filter. BINARY will return a black and white image, GRAYSCALE will return an antialiased grayscale image.*/
|
|
49
|
-
outputMode: OutputMode;
|
|
50
|
-
|
|
51
|
-
/** Value controlling the amount of noise removal. Value between 0 and 1.
|
|
52
|
-
Too little noise removal may result in a very noisy image, worsening readability.
|
|
53
|
-
Too much noise removal may result in the degradation of text, again, worsening readability.
|
|
54
|
-
*/
|
|
55
|
-
denoise: number;
|
|
56
|
-
|
|
57
|
-
/** Filter radius. The bigger the radius, the slower the filter and generally the less noise in the result.
|
|
58
|
-
The radius is used for both shadows removal and the calculation of local statistics in the main body of the filter.
|
|
59
|
-
Higher radius usually allows to cope better with regions of light text on dark background.
|
|
60
|
-
All the values larger than 512 are clamped to 512.
|
|
61
|
-
*/
|
|
62
|
-
radius: number;
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
/** @internal */
|
|
66
|
-
toWireType(): any;
|
|
67
|
-
}
|
|
68
|
-
/** Color document filter. This filter is a good starting point for most use cases.*/
|
|
69
|
-
export class ColorDocumentFilter {
|
|
70
|
-
|
|
71
|
-
/** Strength of contrast enhancement. Typical values are between 1 and 2.*/
|
|
72
|
-
valueStrength: number;
|
|
73
|
-
|
|
74
|
-
/** Strength of color saturation enhancement. Typical values are between 1 and 2.*/
|
|
75
|
-
saturationStrength: number;
|
|
76
|
-
|
|
77
|
-
/** Saturation level separating colors from paper.*/
|
|
78
|
-
saturationOffset: number;
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
/** @internal */
|
|
82
|
-
toWireType(): any;
|
|
83
|
-
}
|
|
84
|
-
/** Brightness adjustment filter.*/
|
|
85
|
-
export class BrightnessFilter {
|
|
86
|
-
|
|
87
|
-
/** Brightness adjustment value in the range from -1 to 1. Negative values will make the image darker, positive values will make it brighter.*/
|
|
88
|
-
brightness: number;
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
/** @internal */
|
|
92
|
-
toWireType(): any;
|
|
93
|
-
}
|
|
94
|
-
/** Contrast adjustment filter.*/
|
|
95
|
-
export class ContrastFilter {
|
|
96
|
-
|
|
97
|
-
/** Contrast adjustment value in the range from -1 to 254 (inclusively). Negative values will decrease the contrast, positive values will increase it.*/
|
|
98
|
-
contrast: number;
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
/** @internal */
|
|
102
|
-
toWireType(): any;
|
|
103
|
-
}
|
|
104
|
-
/** Converts color images to grayscale, optionally applying autocontrast.*/
|
|
105
|
-
export class GrayscaleFilter {
|
|
106
|
-
|
|
107
|
-
/** Enable or disable autocontrast.
|
|
108
|
-
*/
|
|
109
|
-
autocontrast: boolean;
|
|
110
|
-
|
|
111
|
-
/** Ignore this fraction of pixels at the edge of the image when calculating statistics.
|
|
112
|
-
|
|
113
|
-
Pixels at the edge of the image typically have poor statistics. Ignoring them
|
|
114
|
-
and using only the inner pixels when calculating certain statistics can
|
|
115
|
-
substantially improve the quality of the result.
|
|
116
|
-
|
|
117
|
-
The value must be less than 0.5 but usually good values are between 0 and 0.15.
|
|
118
|
-
*/
|
|
119
|
-
borderWidthFraction: number;
|
|
120
|
-
|
|
121
|
-
/** Clip this fraction of the darkest pixels in operations such as autocontrast.
|
|
122
|
-
|
|
123
|
-
Increasing the range of middle gray levels at the expense of the brightest and darkest levels
|
|
124
|
-
may improve the overall contrast and quality of the result.
|
|
125
|
-
|
|
126
|
-
Sum of blackOutliersFraction and whiteOutliersFraction must be less than 1 but usually
|
|
127
|
-
good values for the parameters do not exceed 0.05;
|
|
128
|
-
*/
|
|
129
|
-
blackOutliersFraction: number;
|
|
130
|
-
|
|
131
|
-
/** Clip this fraction of the brightest pixels in operations such as autocontrast.
|
|
132
|
-
|
|
133
|
-
Increasing the range of middle gray levels at the expense of the brightest and darkest levels
|
|
134
|
-
may improve the overall contrast and quality of the result.
|
|
135
|
-
|
|
136
|
-
Sum of blackOutliersFraction and whiteOutliersFraction must be less than 1 but usually
|
|
137
|
-
good values for the parameters do not exceed 0.05;
|
|
138
|
-
*/
|
|
139
|
-
whiteOutliersFraction: number;
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
/** @internal */
|
|
143
|
-
toWireType(): any;
|
|
144
|
-
}
|
|
145
|
-
/** Deprecated image filters.*/
|
|
146
|
-
export class LegacyFilter {
|
|
147
|
-
|
|
148
|
-
/** Id of filter to be applied.*/
|
|
149
|
-
filterType: number;
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
/** @internal */
|
|
153
|
-
toWireType(): any;
|
|
154
|
-
}
|
|
155
|
-
/** Maps image value channel so that all the pixels darker than the black point are set to 0,
|
|
156
|
-
all the pixels brighter than the white point are set to 255, and the pixels in between
|
|
157
|
-
are linearly scaled.
|
|
158
|
-
*/
|
|
159
|
-
export class WhiteBlackPointFilter {
|
|
160
|
-
|
|
161
|
-
/** Fraction of the value channel range that is set to 0. The value should be in the range from 0 to 1.*/
|
|
162
|
-
blackPoint: number;
|
|
163
|
-
|
|
164
|
-
/** Fraction of the value channel range that is not set to 255. The value should be in the range from 0 to 1.*/
|
|
165
|
-
whitePoint: number;
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
/** @internal */
|
|
169
|
-
toWireType(): any;
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
export type ParametricFilter =
|
|
173
|
-
ScanbotBinarizationFilter |
|
|
174
|
-
CustomBinarizationFilter |
|
|
175
|
-
ColorDocumentFilter |
|
|
176
|
-
BrightnessFilter |
|
|
177
|
-
ContrastFilter |
|
|
178
|
-
GrayscaleFilter |
|
|
179
|
-
LegacyFilter |
|
|
180
|
-
WhiteBlackPointFilter;
|
|
181
|
-
|
package/@types/core/utils.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export function areThreadsAvailable(): boolean;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
export class WorkerBridgeInitOptions {
|
|
3
|
-
allowSimd?: boolean;
|
|
4
|
-
allowThreads?: boolean;
|
|
5
|
-
requestSuffix?: string;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
export class WorkerBridge {
|
|
9
|
-
constructor(basePath: string, options: WorkerBridgeInitOptions);
|
|
10
|
-
|
|
11
|
-
post(command: string, args: any[], copyArgs: boolean): Promise<any>;
|
|
12
|
-
|
|
13
|
-
// Create a copy and pass it to the worker
|
|
14
|
-
postByCopyingArgs(command: string, args: any[]): Promise<any>;
|
|
15
|
-
|
|
16
|
-
// Directly transfer the args to the worker
|
|
17
|
-
postByTransferringArgs(command: string, args: any[]): Promise<any>;
|
|
18
|
-
|
|
19
|
-
destroy(): void;
|
|
20
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type BarcodeFormat = "ONE_D" | "AZTEC" | "CODABAR" | "CODE_39" | "CODE_93" | "CODE_128" | "DATA_MATRIX" | "EAN_8" | "EAN_13" | "ITF" | "MAXICODE" | "PDF_417" | "QR_CODE" | "UPC_A" | "UPC_E" | "UPC_EAN_EXTENSION" | "MSI_PLESSEY" | "IATA_2_OF_5" | "INDUSTRIAL_2_OF_5" | "CODE_25" | "MICRO_QR_CODE" | "USPS_INTELLIGENT_MAIL" | "ROYAL_MAIL" | "JAPAN_POST" | "ROYAL_TNT_POST" | "AUSTRALIA_POST" | "DATABAR" | "DATABAR_EXPANDED" | "DATABAR_LIMITED" | "GS1_COMPOSITE";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type EngineMode = "NEXT_GEN" | "LEGACY";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export default class DocumentQualityAnalyzerConfiguration {
|
|
2
|
-
/**
|
|
3
|
-
* Patch size should be approx. 512-768. It governs the trade-off between speed and memory usage.
|
|
4
|
-
* Smaller patch sizes use less memory but take longer. Defaults to 512.
|
|
5
|
-
*/
|
|
6
|
-
patchSize: number;
|
|
7
|
-
/**
|
|
8
|
-
* Images with a side length larger than maxImageSize will be downscaled before analysing.
|
|
9
|
-
* This is useful to reduce memory usage and processing time for large images.
|
|
10
|
-
* Set to -1 to disable downscaling.
|
|
11
|
-
*/
|
|
12
|
-
maxImageSize: number;
|
|
13
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { MagneticLine } from "../../utils/dto/MagneticLine";
|
|
2
|
-
import { Polygon } from "../../utils/dto/Polygon";
|
|
3
|
-
import { DetectionStatus } from "./detection-status";
|
|
4
|
-
export declare class ContourDetectionResult {
|
|
5
|
-
horizontalLines?: MagneticLine[];
|
|
6
|
-
verticalLines?: MagneticLine[];
|
|
7
|
-
polygon?: Polygon;
|
|
8
|
-
detectionStatus?: DetectionStatus;
|
|
9
|
-
success?: boolean;
|
|
10
|
-
constructor(contourDetectionResult?: ContourDetectionResult);
|
|
11
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export declare enum DetectionStatus {
|
|
2
|
-
NotAcquired = "NotAcquired",
|
|
3
|
-
OK = "OK",
|
|
4
|
-
OK_SmallSize = "OK_SmallSize",
|
|
5
|
-
OK_BadAngles = "OK_BadAngles",
|
|
6
|
-
OK_BadAspectRatio = "OK_BadAspectRatio",
|
|
7
|
-
OK_OffCenter = "OK_OffCenter",
|
|
8
|
-
Error_NothingDetected = "Error_NothingDetected",
|
|
9
|
-
Error_Brightness = "Error_Brightness",
|
|
10
|
-
Error_Noise = "Error_Noise"
|
|
11
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { VideoSize } from "../../utils/dto/VideoSize";
|
|
2
|
-
import { ContourDetectionResult } from "./contour-detection-result";
|
|
3
|
-
export declare class DocumentDetectionResult extends ContourDetectionResult {
|
|
4
|
-
cropped?: Uint8Array;
|
|
5
|
-
original: Uint8Array;
|
|
6
|
-
videoSize: VideoSize;
|
|
7
|
-
constructor(contourDetectionResult?: ContourDetectionResult);
|
|
8
|
-
}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export type BinarizationFilter = 'binarized' | 'otsuBinarization' | 'pureBinarized' | 'lowLightBinarization' | 'lowLightBinarization2' | 'deepBinarization';
|
|
2
|
-
export type ColorFilter = 'color' | 'gray' | 'colorDocument' | 'blackAndWhite' | 'edgeHighlight';
|
|
3
|
-
/**
|
|
4
|
-
* @deprecated Use the new ImageProcessor API instead (see {@link ScanbotSDK.createImageProcessor}).
|
|
5
|
-
*/
|
|
6
|
-
export type ImageFilter = BinarizationFilter | ColorFilter;
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
export type MRZFieldValidationStatus = 'Success' | 'Failure' | 'NotValidated';
|
|
2
|
-
export declare class MrzField {
|
|
3
|
-
name?: string;
|
|
4
|
-
value?: string;
|
|
5
|
-
confidence?: number;
|
|
6
|
-
validated?: MRZFieldValidationStatus;
|
|
7
|
-
constructor(name?: string, value?: string, confidence?: number, validated?: MRZFieldValidationStatus);
|
|
8
|
-
}
|
|
9
|
-
export declare class MrzCheckDigits {
|
|
10
|
-
general?: MrzField;
|
|
11
|
-
documentNumber?: MrzField;
|
|
12
|
-
birthDate?: MrzField;
|
|
13
|
-
expiryDate?: MrzField;
|
|
14
|
-
personalNumber?: MrzField;
|
|
15
|
-
}
|
|
16
|
-
export declare class MrzResult {
|
|
17
|
-
documentNumber?: MrzField;
|
|
18
|
-
issuingAuthority?: MrzField;
|
|
19
|
-
departmentOfIssuance?: MrzField;
|
|
20
|
-
givenNames?: MrzField;
|
|
21
|
-
surname?: MrzField;
|
|
22
|
-
nationality?: MrzField;
|
|
23
|
-
birthDate?: MrzField;
|
|
24
|
-
gender?: MrzField;
|
|
25
|
-
expiryDate?: MrzField;
|
|
26
|
-
personalNumber?: MrzField;
|
|
27
|
-
travelDocType?: MrzField;
|
|
28
|
-
travelDocTypeVariant?: MrzField;
|
|
29
|
-
optional1?: MrzField;
|
|
30
|
-
optional2?: MrzField;
|
|
31
|
-
discreetIssuingStateOrOrganization?: MrzField;
|
|
32
|
-
kindOfDocumentField?: MrzField;
|
|
33
|
-
documentType?: MrzField;
|
|
34
|
-
format?: MrzField;
|
|
35
|
-
pinCode?: MrzField;
|
|
36
|
-
languageCode?: MrzField;
|
|
37
|
-
versionNumber?: MrzField;
|
|
38
|
-
checkDigits?: MrzCheckDigits;
|
|
39
|
-
verificationSuccessful?: boolean;
|
|
40
|
-
static fromWorker(inputs: any): MrzResult;
|
|
41
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export type DocumentQuality = "NO_DOCUMENT" | "VERY_POOR" | "POOR" | "REASONABLE" | "GOOD" | "EXCELLENT";
|
|
2
|
-
export default interface DocumentQualityAnalyzerResult {
|
|
3
|
-
/**
|
|
4
|
-
* Result of document quality analysis.
|
|
5
|
-
* It is used to determine if the document is good enough to be used for OCR processing.
|
|
6
|
-
*/
|
|
7
|
-
quality: DocumentQuality;
|
|
8
|
-
}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import ScanbotSDK from "../scanbot-sdk";
|
|
2
|
-
import { ParametricFilter } from "../core/compiled/ParametricFilters";
|
|
3
|
-
import { Polygon } from "../utils/dto/Polygon";
|
|
4
|
-
export type Rotation = "ROTATION_NONE" | "ROTATION_90_CLOCKWISE" | "ROTATION_180" | "ROTATION_90_COUNTERCLOCKWISE";
|
|
5
|
-
export declare class ImageProcessor {
|
|
6
|
-
private _sdk;
|
|
7
|
-
private _token;
|
|
8
|
-
/** @internal */
|
|
9
|
-
constructor(_sdk: ScanbotSDK, _token: string);
|
|
10
|
-
copy(): Promise<ImageProcessor>;
|
|
11
|
-
/**
|
|
12
|
-
* Applies the given filter to the image.
|
|
13
|
-
* See {@link ParametricFilters} for available filters.
|
|
14
|
-
* @example
|
|
15
|
-
* imageProcessor.applyFilter(new sdk.imageFilters.ScanbotBinarizationFilter());
|
|
16
|
-
* */
|
|
17
|
-
applyFilter(filter: ParametricFilter): Promise<void>;
|
|
18
|
-
/**
|
|
19
|
-
* Crops the image to the given polygon.
|
|
20
|
-
* The polygon is defined by an array of four points, each point being an object with `x` and `y` coordinates.
|
|
21
|
-
* Each coordinate is a floating point number between 0 and 1, representing the percentage of the image width and height, respectively.
|
|
22
|
-
* @example
|
|
23
|
-
* // Crop an image to the center 80% of the image:
|
|
24
|
-
* imageProcessor.crop([{x: 0.1, y: 0.1}, {x: 0.9, y: 0.1}, {x: 0.9, y: 0.9}, {x: 0.1, y: 0.9}])
|
|
25
|
-
*/
|
|
26
|
-
crop(polygon: Polygon): Promise<void>;
|
|
27
|
-
/** Resizes image, keeping aspect ratio, so that the biggest side of the image is equal to `destinationSize`. */
|
|
28
|
-
resize(destinationSize: number): Promise<void>;
|
|
29
|
-
rotate(rotation: Rotation): Promise<void>;
|
|
30
|
-
/** Returns the processed image as a JPEG encoded ArrayBuffer. */
|
|
31
|
-
processedImage(): Promise<ArrayBuffer>;
|
|
32
|
-
release(): Promise<void>;
|
|
33
|
-
/** @internal */
|
|
34
|
-
get __token(): string;
|
|
35
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { BarcodeItem } from "./BarcodeItem";
|
|
2
|
-
import { DeepPartial, PartiallyConstructible } from "./utils";
|
|
3
|
-
/**
|
|
4
|
-
Results of the barcode scan.
|
|
5
|
-
*/
|
|
6
|
-
export declare class BarcodeScannerResult extends PartiallyConstructible {
|
|
7
|
-
/**
|
|
8
|
-
Recognized barcode items.
|
|
9
|
-
@defaultValue [];
|
|
10
|
-
*/
|
|
11
|
-
items: BarcodeItem[];
|
|
12
|
-
/** @param source {@displayType `DeepPartial<BarcodeScannerResult>`} */
|
|
13
|
-
constructor(source?: DeepPartial<BarcodeScannerResult>);
|
|
14
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { BarcodeResult } from "../model/barcode/barcode-result";
|
|
2
|
-
import { ImageDataWrapper } from "../model/image-data-wrapper";
|
|
3
|
-
export default class Networking {
|
|
4
|
-
static postBlob(url: string, blob: Blob): Promise<any>;
|
|
5
|
-
static postImage(url: string, imageData: ImageDataWrapper): Promise<any>;
|
|
6
|
-
static recognizeBarcodes(url: string, imageData: ImageDataWrapper): Promise<BarcodeResult>;
|
|
7
|
-
}
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|