@techstark/opencv-js 4.8.0-release.1 → 4.8.0-release.10

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.
Files changed (200) hide show
  1. package/README.md +130 -1
  2. package/dist/README.md +20 -1
  3. package/dist/src/index.d.ts +1 -0
  4. package/dist/src/index.js +18 -0
  5. package/dist/src/index.js.map +1 -0
  6. package/dist/src/types/_cv.d.ts +7 -0
  7. package/dist/src/types/_cv.js +3 -0
  8. package/dist/src/types/_cv.js.map +1 -0
  9. package/dist/src/types/emscripten.d.ts +166 -0
  10. package/dist/src/types/emscripten.js +4 -0
  11. package/dist/src/types/emscripten.js.map +1 -0
  12. package/dist/src/types/opencv/Affine3.d.ts +183 -0
  13. package/dist/src/types/opencv/Affine3.js +3 -0
  14. package/dist/src/types/opencv/Affine3.js.map +1 -0
  15. package/dist/src/types/opencv/Algorithm.d.ts +105 -0
  16. package/dist/src/types/opencv/Algorithm.js +4 -0
  17. package/dist/src/types/opencv/Algorithm.js.map +1 -0
  18. package/dist/src/types/opencv/AutoBuffer.d.ts +41 -0
  19. package/dist/src/types/opencv/AutoBuffer.js +3 -0
  20. package/dist/src/types/opencv/AutoBuffer.js.map +1 -0
  21. package/dist/src/types/opencv/BFMatcher.d.ts +33 -0
  22. package/dist/src/types/opencv/BFMatcher.js +3 -0
  23. package/dist/src/types/opencv/BFMatcher.js.map +1 -0
  24. package/dist/src/types/opencv/BOWTrainer.d.ts +36 -0
  25. package/dist/src/types/opencv/BOWTrainer.js +3 -0
  26. package/dist/src/types/opencv/BOWTrainer.js.map +1 -0
  27. package/dist/src/types/opencv/CascadeClassifier.d.ts +100 -0
  28. package/dist/src/types/opencv/CascadeClassifier.js +4 -0
  29. package/dist/src/types/opencv/CascadeClassifier.js.map +1 -0
  30. package/dist/src/types/opencv/DescriptorMatcher.d.ts +172 -0
  31. package/dist/src/types/opencv/DescriptorMatcher.js +3 -0
  32. package/dist/src/types/opencv/DescriptorMatcher.js.map +1 -0
  33. package/dist/src/types/opencv/DynamicBitset.d.ts +57 -0
  34. package/dist/src/types/opencv/DynamicBitset.js +3 -0
  35. package/dist/src/types/opencv/DynamicBitset.js.map +1 -0
  36. package/dist/src/types/opencv/Exception.d.ts +38 -0
  37. package/dist/src/types/opencv/Exception.js +3 -0
  38. package/dist/src/types/opencv/Exception.js.map +1 -0
  39. package/dist/src/types/opencv/Feature2D.d.ts +14 -0
  40. package/dist/src/types/opencv/Feature2D.js +4 -0
  41. package/dist/src/types/opencv/Feature2D.js.map +1 -0
  42. package/dist/src/types/opencv/FlannBasedMatcher.d.ts +41 -0
  43. package/dist/src/types/opencv/FlannBasedMatcher.js +3 -0
  44. package/dist/src/types/opencv/FlannBasedMatcher.js.map +1 -0
  45. package/dist/src/types/opencv/HOGDescriptor.d.ts +265 -0
  46. package/dist/src/types/opencv/HOGDescriptor.js +3 -0
  47. package/dist/src/types/opencv/HOGDescriptor.js.map +1 -0
  48. package/dist/src/types/opencv/Logger.d.ts +27 -0
  49. package/dist/src/types/opencv/Logger.js +3 -0
  50. package/dist/src/types/opencv/Logger.js.map +1 -0
  51. package/dist/src/types/opencv/LshTable.d.ts +67 -0
  52. package/dist/src/types/opencv/LshTable.js +3 -0
  53. package/dist/src/types/opencv/LshTable.js.map +1 -0
  54. package/dist/src/types/opencv/Mat.d.ts +1589 -0
  55. package/dist/src/types/opencv/Mat.js +4 -0
  56. package/dist/src/types/opencv/Mat.js.map +1 -0
  57. package/dist/src/types/opencv/MatExpr.d.ts +78 -0
  58. package/dist/src/types/opencv/MatExpr.js +4 -0
  59. package/dist/src/types/opencv/MatExpr.js.map +1 -0
  60. package/dist/src/types/opencv/MatOp.d.ts +29 -0
  61. package/dist/src/types/opencv/MatOp.js +3 -0
  62. package/dist/src/types/opencv/MatOp.js.map +1 -0
  63. package/dist/src/types/opencv/Matx.d.ts +84 -0
  64. package/dist/src/types/opencv/Matx.js +3 -0
  65. package/dist/src/types/opencv/Matx.js.map +1 -0
  66. package/dist/src/types/opencv/Node.d.ts +25 -0
  67. package/dist/src/types/opencv/Node.js +3 -0
  68. package/dist/src/types/opencv/Node.js.map +1 -0
  69. package/dist/src/types/opencv/ORB.d.ts +11 -0
  70. package/dist/src/types/opencv/ORB.js +4 -0
  71. package/dist/src/types/opencv/ORB.js.map +1 -0
  72. package/dist/src/types/opencv/PCA.d.ts +170 -0
  73. package/dist/src/types/opencv/PCA.js +3 -0
  74. package/dist/src/types/opencv/PCA.js.map +1 -0
  75. package/dist/src/types/opencv/RotatedRect.d.ts +63 -0
  76. package/dist/src/types/opencv/RotatedRect.js +3 -0
  77. package/dist/src/types/opencv/RotatedRect.js.map +1 -0
  78. package/dist/src/types/opencv/_hacks.d.ts +270 -0
  79. package/dist/src/types/opencv/_hacks.js +10 -0
  80. package/dist/src/types/opencv/_hacks.js.map +1 -0
  81. package/dist/src/types/opencv/_types.d.ts +44 -0
  82. package/dist/src/types/opencv/_types.js +61 -0
  83. package/dist/src/types/opencv/_types.js.map +1 -0
  84. package/dist/src/types/opencv/calib3d.d.ts +2180 -0
  85. package/dist/src/types/opencv/calib3d.js +3 -0
  86. package/dist/src/types/opencv/calib3d.js.map +1 -0
  87. package/dist/src/types/opencv/core_array.d.ts +2513 -0
  88. package/dist/src/types/opencv/core_array.js +3 -0
  89. package/dist/src/types/opencv/core_array.js.map +1 -0
  90. package/dist/src/types/opencv/core_cluster.d.ts +54 -0
  91. package/dist/src/types/opencv/core_cluster.js +3 -0
  92. package/dist/src/types/opencv/core_cluster.js.map +1 -0
  93. package/dist/src/types/opencv/core_hal_interface.d.ts +92 -0
  94. package/dist/src/types/opencv/core_hal_interface.js +3 -0
  95. package/dist/src/types/opencv/core_hal_interface.js.map +1 -0
  96. package/dist/src/types/opencv/core_utils.d.ts +510 -0
  97. package/dist/src/types/opencv/core_utils.js +3 -0
  98. package/dist/src/types/opencv/core_utils.js.map +1 -0
  99. package/dist/src/types/opencv/dnn.d.ts +336 -0
  100. package/dist/src/types/opencv/dnn.js +3 -0
  101. package/dist/src/types/opencv/dnn.js.map +1 -0
  102. package/dist/src/types/opencv/features2d_draw.d.ts +75 -0
  103. package/dist/src/types/opencv/features2d_draw.js +3 -0
  104. package/dist/src/types/opencv/features2d_draw.js.map +1 -0
  105. package/dist/src/types/opencv/imgproc_color_conversions.d.ts +299 -0
  106. package/dist/src/types/opencv/imgproc_color_conversions.js +3 -0
  107. package/dist/src/types/opencv/imgproc_color_conversions.js.map +1 -0
  108. package/dist/src/types/opencv/imgproc_draw.d.ts +502 -0
  109. package/dist/src/types/opencv/imgproc_draw.js +3 -0
  110. package/dist/src/types/opencv/imgproc_draw.js.map +1 -0
  111. package/dist/src/types/opencv/imgproc_feature.d.ts +533 -0
  112. package/dist/src/types/opencv/imgproc_feature.js +3 -0
  113. package/dist/src/types/opencv/imgproc_feature.js.map +1 -0
  114. package/dist/src/types/opencv/imgproc_filter.d.ts +689 -0
  115. package/dist/src/types/opencv/imgproc_filter.js +3 -0
  116. package/dist/src/types/opencv/imgproc_filter.js.map +1 -0
  117. package/dist/src/types/opencv/imgproc_hist.d.ts +291 -0
  118. package/dist/src/types/opencv/imgproc_hist.js +3 -0
  119. package/dist/src/types/opencv/imgproc_hist.js.map +1 -0
  120. package/dist/src/types/opencv/imgproc_misc.d.ts +473 -0
  121. package/dist/src/types/opencv/imgproc_misc.js +3 -0
  122. package/dist/src/types/opencv/imgproc_misc.js.map +1 -0
  123. package/dist/src/types/opencv/imgproc_object.d.ts +41 -0
  124. package/dist/src/types/opencv/imgproc_object.js +3 -0
  125. package/dist/src/types/opencv/imgproc_object.js.map +1 -0
  126. package/dist/src/types/opencv/imgproc_shape.d.ts +570 -0
  127. package/dist/src/types/opencv/imgproc_shape.js +3 -0
  128. package/dist/src/types/opencv/imgproc_shape.js.map +1 -0
  129. package/dist/src/types/opencv/imgproc_transform.d.ts +430 -0
  130. package/dist/src/types/opencv/imgproc_transform.js +3 -0
  131. package/dist/src/types/opencv/imgproc_transform.js.map +1 -0
  132. package/dist/src/types/opencv/index.d.ts +4 -0
  133. package/dist/src/types/opencv/index.js +19 -0
  134. package/dist/src/types/opencv/index.js.map +1 -0
  135. package/dist/src/types/opencv/objdetect.d.ts +43 -0
  136. package/dist/src/types/opencv/objdetect.js +3 -0
  137. package/dist/src/types/opencv/objdetect.js.map +1 -0
  138. package/dist/src/types/opencv/photo_inpaint.d.ts +25 -0
  139. package/dist/src/types/opencv/photo_inpaint.js +3 -0
  140. package/dist/src/types/opencv/photo_inpaint.js.map +1 -0
  141. package/dist/src/types/opencv/softdouble.d.ts +38 -0
  142. package/dist/src/types/opencv/softdouble.js +3 -0
  143. package/dist/src/types/opencv/softdouble.js.map +1 -0
  144. package/dist/src/types/opencv/softfloat.d.ts +38 -0
  145. package/dist/src/types/opencv/softfloat.js +3 -0
  146. package/dist/src/types/opencv/softfloat.js.map +1 -0
  147. package/dist/src/types/opencv/video_track.d.ts +276 -0
  148. package/dist/src/types/opencv/video_track.js +3 -0
  149. package/dist/src/types/opencv/video_track.js.map +1 -0
  150. package/package.json +15 -6
  151. package/src/index.ts +1 -0
  152. package/src/types/_cv.ts +6 -0
  153. package/src/types/emscripten.ts +286 -0
  154. package/src/types/opencv/Affine3.ts +206 -0
  155. package/src/types/opencv/Algorithm.ts +126 -0
  156. package/src/types/opencv/AutoBuffer.ts +50 -0
  157. package/src/types/opencv/BFMatcher.ts +37 -0
  158. package/src/types/opencv/BOWTrainer.ts +43 -0
  159. package/src/types/opencv/CascadeClassifier.ts +153 -0
  160. package/src/types/opencv/DescriptorMatcher.ts +244 -0
  161. package/src/types/opencv/DynamicBitset.ts +68 -0
  162. package/src/types/opencv/Exception.ts +54 -0
  163. package/src/types/opencv/Feature2D.ts +20 -0
  164. package/src/types/opencv/FlannBasedMatcher.ts +50 -0
  165. package/src/types/opencv/HOGDescriptor.ts +401 -0
  166. package/src/types/opencv/Logger.ts +34 -0
  167. package/src/types/opencv/LshTable.ts +81 -0
  168. package/src/types/opencv/Mat.ts +1765 -0
  169. package/src/types/opencv/MatExpr.ts +107 -0
  170. package/src/types/opencv/MatOp.ts +70 -0
  171. package/src/types/opencv/Matx.ts +228 -0
  172. package/src/types/opencv/Node.ts +33 -0
  173. package/src/types/opencv/ORB.ts +22 -0
  174. package/src/types/opencv/PCA.ts +204 -0
  175. package/src/types/opencv/RotatedRect.ts +72 -0
  176. package/src/types/opencv/_hacks.ts +321 -0
  177. package/src/types/opencv/_types.ts +44 -0
  178. package/src/types/opencv/calib3d.ts +2937 -0
  179. package/src/types/opencv/core_array.ts +3102 -0
  180. package/src/types/opencv/core_cluster.ts +81 -0
  181. package/src/types/opencv/core_hal_interface.ts +159 -0
  182. package/src/types/opencv/core_utils.ts +748 -0
  183. package/src/types/opencv/dnn.ts +505 -0
  184. package/src/types/opencv/features2d_draw.ts +114 -0
  185. package/src/types/opencv/imgproc_color_conversions.ts +527 -0
  186. package/src/types/opencv/imgproc_draw.ts +733 -0
  187. package/src/types/opencv/imgproc_feature.ts +681 -0
  188. package/src/types/opencv/imgproc_filter.ts +918 -0
  189. package/src/types/opencv/imgproc_hist.ts +399 -0
  190. package/src/types/opencv/imgproc_misc.ts +616 -0
  191. package/src/types/opencv/imgproc_object.ts +58 -0
  192. package/src/types/opencv/imgproc_shape.ts +734 -0
  193. package/src/types/opencv/imgproc_transform.ts +574 -0
  194. package/src/types/opencv/index.ts +4 -0
  195. package/src/types/opencv/objdetect.ts +103 -0
  196. package/src/types/opencv/photo_inpaint.ts +37 -0
  197. package/src/types/opencv/softdouble.ts +64 -0
  198. package/src/types/opencv/softfloat.ts +64 -0
  199. package/src/types/opencv/video_track.ts +372 -0
  200. package/dist/types/index.d.ts +0 -1
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=core_array.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core_array.js","sourceRoot":"","sources":["../../../../src/types/opencv/core_array.ts"],"names":[],"mappings":""}
@@ -0,0 +1,54 @@
1
+ import { double, InputArray, InputOutputArray, int, OutputArray, TermCriteria, _EqPredicate } from "./_types";
2
+ /**
3
+ * The function kmeans implements a k-means algorithm that finds the centers of cluster_count clusters
4
+ * and groups the input samples around the clusters. As an output, `$\\texttt{bestLabels}_i$` contains
5
+ * a 0-based cluster index for the sample stored in the `$i^{th}$` row of the samples matrix.
6
+ *
7
+ * (Python) An example on K-means clustering can be found at
8
+ * opencv_source_code/samples/python/kmeans.py
9
+ *
10
+ * The function returns the compactness measure that is computed as `\\[\\sum _i \\| \\texttt{samples}
11
+ * _i - \\texttt{centers} _{ \\texttt{labels} _i} \\| ^2\\]` after every attempt. The best (minimum)
12
+ * value is chosen and the corresponding labels and the compactness value are returned by the function.
13
+ * Basically, you can use only the core of the function, set the number of attempts to 1, initialize
14
+ * labels each time using a custom algorithm, pass them with the ( flags = [KMEANS_USE_INITIAL_LABELS]
15
+ * ) flag, and then choose the best (most-compact) clustering.
16
+ *
17
+ * @param data Data for clustering. An array of N-Dimensional points with float coordinates is needed.
18
+ * Examples of this array can be:
19
+ * Mat points(count, 2, CV_32F);Mat points(count, 1, CV_32FC2);Mat points(1, count,
20
+ * CV_32FC2);std::vector<cv::Point2f> points(sampleCount);
21
+ *
22
+ * @param K Number of clusters to split the set by.
23
+ *
24
+ * @param bestLabels Input/output integer array that stores the cluster indices for every sample.
25
+ *
26
+ * @param criteria The algorithm termination criteria, that is, the maximum number of iterations and/or
27
+ * the desired accuracy. The accuracy is specified as criteria.epsilon. As soon as each of the cluster
28
+ * centers moves by less than criteria.epsilon on some iteration, the algorithm stops.
29
+ *
30
+ * @param attempts Flag to specify the number of times the algorithm is executed using different
31
+ * initial labellings. The algorithm returns the labels that yield the best compactness (see the last
32
+ * function parameter).
33
+ *
34
+ * @param flags Flag that can take values of cv::KmeansFlags
35
+ *
36
+ * @param centers Output matrix of the cluster centers, one row per each cluster center.
37
+ */
38
+ export declare function kmeans(data: InputArray, K: int, bestLabels: InputOutputArray, criteria: TermCriteria, attempts: int, flags: int, centers?: OutputArray): double;
39
+ /**
40
+ * The generic function partition implements an `$O(N^2)$` algorithm for splitting a set of `$N$`
41
+ * elements into one or more equivalency classes, as described in . The function returns the number of
42
+ * equivalency classes.
43
+ *
44
+ * @param _vec Set of elements stored as a vector.
45
+ *
46
+ * @param labels Output vector of labels. It contains as many elements as vec. Each label labels[i] is
47
+ * a 0-based cluster index of vec[i].
48
+ *
49
+ * @param predicate Equivalence predicate (pointer to a boolean function of two arguments or an
50
+ * instance of the class that has the method bool operator()(const _Tp& a, const _Tp& b) ). The
51
+ * predicate returns true when the elements are certainly in the same class, and returns false if they
52
+ * may or may not be in the same class.
53
+ */
54
+ export declare function partition(arg119: any, arg120: any, _vec: any, labels: any, predicate?: _EqPredicate): any;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=core_cluster.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core_cluster.js","sourceRoot":"","sources":["../../../../src/types/opencv/core_cluster.ts"],"names":[],"mappings":""}
@@ -0,0 +1,92 @@
1
+ import { cvhalDFT, int, size_t, uchar } from "./_types";
2
+ /**
3
+ * @param context pointer to context storing all necessary data
4
+ *
5
+ * @param src_data source image data and step
6
+ *
7
+ * @param dst_data destination image data and step
8
+ */
9
+ export declare function hal_ni_dct2D(context: cvhalDFT, src_data: uchar, src_step: size_t, dst_data: uchar, dst_step: size_t): cvhalDFT;
10
+ /**
11
+ * @param context pointer to context storing all necessary data
12
+ */
13
+ export declare function hal_ni_dctFree2D(context: cvhalDFT): cvhalDFT;
14
+ /**
15
+ * @param context double pointer to context storing all necessary data
16
+ *
17
+ * @param width image dimensions
18
+ *
19
+ * @param depth image type (CV_32F or CV64F)
20
+ *
21
+ * @param flags algorithm options (combination of CV_HAL_DFT_INVERSE, ...)
22
+ */
23
+ export declare function hal_ni_dctInit2D(context: cvhalDFT, width: int, height: int, depth: int, flags: int): cvhalDFT;
24
+ /**
25
+ * @param context pointer to context storing all necessary data
26
+ *
27
+ * @param src source data
28
+ *
29
+ * @param dst destination data
30
+ */
31
+ export declare function hal_ni_dft1D(context: cvhalDFT, src: uchar, dst: uchar): cvhalDFT;
32
+ /**
33
+ * @param context pointer to context storing all necessary data
34
+ *
35
+ * @param src_data source image data and step
36
+ *
37
+ * @param dst_data destination image data and step
38
+ */
39
+ export declare function hal_ni_dft2D(context: cvhalDFT, src_data: uchar, src_step: size_t, dst_data: uchar, dst_step: size_t): cvhalDFT;
40
+ /**
41
+ * @param context pointer to context storing all necessary data
42
+ */
43
+ export declare function hal_ni_dftFree1D(context: cvhalDFT): cvhalDFT;
44
+ /**
45
+ * @param context pointer to context storing all necessary data
46
+ */
47
+ export declare function hal_ni_dftFree2D(context: cvhalDFT): cvhalDFT;
48
+ /**
49
+ * @param context double pointer to context storing all necessary data
50
+ *
51
+ * @param len transformed array length
52
+ *
53
+ * @param count estimated transformation count
54
+ *
55
+ * @param depth array type (CV_32F or CV_64F)
56
+ *
57
+ * @param flags algorithm options (combination of CV_HAL_DFT_INVERSE, CV_HAL_DFT_SCALE, ...)
58
+ *
59
+ * @param needBuffer pointer to boolean variable, if valid pointer provided, then variable value should
60
+ * be set to true to signal that additional memory buffer is needed for operations
61
+ */
62
+ export declare function hal_ni_dftInit1D(context: cvhalDFT, len: int, count: int, depth: int, flags: int, needBuffer: any): cvhalDFT;
63
+ /**
64
+ * @param context double pointer to context storing all necessary data
65
+ *
66
+ * @param width image dimensions
67
+ *
68
+ * @param depth image type (CV_32F or CV64F)
69
+ *
70
+ * @param src_channels number of channels in input image
71
+ *
72
+ * @param dst_channels number of channels in output image
73
+ *
74
+ * @param flags algorithm options (combination of CV_HAL_DFT_INVERSE, ...)
75
+ *
76
+ * @param nonzero_rows number of nonzero rows in image, can be used for optimization
77
+ */
78
+ export declare function hal_ni_dftInit2D(context: cvhalDFT, width: int, height: int, depth: int, src_channels: int, dst_channels: int, flags: int, nonzero_rows: int): cvhalDFT;
79
+ /**
80
+ * @param src_data Source image
81
+ *
82
+ * @param width Source image dimensions
83
+ *
84
+ * @param depth Depth of source image
85
+ *
86
+ * @param minVal Pointer to the returned global minimum and maximum in an array.
87
+ *
88
+ * @param minIdx Pointer to the returned minimum and maximum location.
89
+ *
90
+ * @param mask Specified array region.
91
+ */
92
+ export declare function hal_ni_minMaxIdx(src_data: uchar, src_step: size_t, width: int, height: int, depth: int, minVal: any, maxVal: any, minIdx: any, maxIdx: any, mask: uchar): uchar;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=core_hal_interface.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core_hal_interface.js","sourceRoot":"","sources":["../../../../src/types/opencv/core_hal_interface.ts"],"names":[],"mappings":""}
@@ -0,0 +1,510 @@
1
+ import { AsyncArray, bool, double, ErrorCallback, float, float16_t, InputArray, InputArrayOfArrays, InputOutputArray, InputOutputArrayOfArrays, int, int64, schar, short, size_t, uchar, uint64, unsigned, ushort, _Tp } from "./_types";
2
+ /**
3
+ * The function returns the aligned pointer of the same type as the input pointer:
4
+ * `\\[\\texttt{(_Tp*)(((size_t)ptr + n-1) & -n)}\\]`
5
+ *
6
+ * @param ptr Aligned pointer.
7
+ *
8
+ * @param n Alignment size that must be a power of two.
9
+ */
10
+ export declare function alignPtr(arg92: any, ptr: any, n?: int): any;
11
+ /**
12
+ * The function returns the minimum number that is greater than or equal to sz and is divisible by n :
13
+ * `\\[\\texttt{(sz + n-1) & -n}\\]`
14
+ *
15
+ * @param sz Buffer size to align.
16
+ *
17
+ * @param n Alignment size that must be a power of two.
18
+ */
19
+ export declare function alignSize(sz: size_t, n: int): size_t;
20
+ /**
21
+ * The function returns true if the host hardware supports the specified feature. When user calls
22
+ * setUseOptimized(false), the subsequent calls to [checkHardwareSupport()] will return false until
23
+ * setUseOptimized(true) is called. This way user can dynamically switch on and off the optimized code
24
+ * in OpenCV.
25
+ *
26
+ * @param feature The feature of interest, one of cv::CpuFeatures
27
+ */
28
+ export declare function checkHardwareSupport(feature: int): bool;
29
+ /**
30
+ * proxy for hal::Cholesky
31
+ */
32
+ export declare function Cholesky(A: any, astep: size_t, m: int, b: any, bstep: size_t, n: int): bool;
33
+ /**
34
+ * proxy for hal::Cholesky
35
+ */
36
+ export declare function Cholesky(A: any, astep: size_t, m: int, b: any, bstep: size_t, n: int): bool;
37
+ /**
38
+ * The function cubeRoot computes `$\\sqrt[3]{\\texttt{val}}$`. Negative arguments are handled
39
+ * correctly. NaN and Inf are not handled. The accuracy approaches the maximum possible accuracy for
40
+ * single-precision data.
41
+ *
42
+ * @param val A function argument.
43
+ */
44
+ export declare function cubeRoot(val: float): float;
45
+ export declare function cv_abs(arg93: any, x: _Tp): any;
46
+ export declare function cv_abs(x: uchar): uchar;
47
+ export declare function cv_abs(x: schar): schar;
48
+ export declare function cv_abs(x: ushort): ushort;
49
+ export declare function cv_abs(x: short): int;
50
+ export declare function CV_XADD(addr: any, delta: int): any;
51
+ /**
52
+ * The function computes an integer i such that: `\\[i \\le \\texttt{value} < i+1\\]`
53
+ *
54
+ * @param value floating-point number. If the value is outside of INT_MIN ... INT_MAX range, the result
55
+ * is not defined.
56
+ */
57
+ export declare function cvCeil(value: double): int;
58
+ /**
59
+ * This is an overloaded member function, provided for convenience. It differs from the above function
60
+ * only in what argument(s) it accepts.
61
+ */
62
+ export declare function cvCeil(value: float): int;
63
+ /**
64
+ * This is an overloaded member function, provided for convenience. It differs from the above function
65
+ * only in what argument(s) it accepts.
66
+ */
67
+ export declare function cvCeil(value: int): int;
68
+ /**
69
+ * The function computes an integer i such that: `\\[i \\le \\texttt{value} < i+1\\]`
70
+ *
71
+ * @param value floating-point number. If the value is outside of INT_MIN ... INT_MAX range, the result
72
+ * is not defined.
73
+ */
74
+ export declare function cvFloor(value: double): int;
75
+ /**
76
+ * This is an overloaded member function, provided for convenience. It differs from the above function
77
+ * only in what argument(s) it accepts.
78
+ */
79
+ export declare function cvFloor(value: float): int;
80
+ /**
81
+ * This is an overloaded member function, provided for convenience. It differs from the above function
82
+ * only in what argument(s) it accepts.
83
+ */
84
+ export declare function cvFloor(value: int): int;
85
+ /**
86
+ * The function returns 1 if the argument is a plus or minus infinity (as defined by IEEE754 standard)
87
+ * and 0 otherwise.
88
+ *
89
+ * @param value The input floating-point value
90
+ */
91
+ export declare function cvIsInf(value: double): int;
92
+ /**
93
+ * This is an overloaded member function, provided for convenience. It differs from the above function
94
+ * only in what argument(s) it accepts.
95
+ */
96
+ export declare function cvIsInf(value: float): int;
97
+ /**
98
+ * The function returns 1 if the argument is Not A Number (as defined by IEEE754 standard), 0
99
+ * otherwise.
100
+ *
101
+ * @param value The input floating-point value
102
+ */
103
+ export declare function cvIsNaN(value: double): int;
104
+ /**
105
+ * This is an overloaded member function, provided for convenience. It differs from the above function
106
+ * only in what argument(s) it accepts.
107
+ */
108
+ export declare function cvIsNaN(value: float): int;
109
+ /**
110
+ * @param value floating-point number. If the value is outside of INT_MIN ... INT_MAX range, the result
111
+ * is not defined.
112
+ */
113
+ export declare function cvRound(value: double): int;
114
+ /**
115
+ * This is an overloaded member function, provided for convenience. It differs from the above function
116
+ * only in what argument(s) it accepts.
117
+ */
118
+ export declare function cvRound(value: float): int;
119
+ /**
120
+ * This is an overloaded member function, provided for convenience. It differs from the above function
121
+ * only in what argument(s) it accepts.
122
+ */
123
+ export declare function cvRound(value: int): int;
124
+ /**
125
+ * Use this function instead of `ceil((float)a / b)` expressions.
126
+ *
127
+ * [alignSize]
128
+ */
129
+ export declare function divUp(a: int, b: any): int;
130
+ /**
131
+ * This is an overloaded member function, provided for convenience. It differs from the above function
132
+ * only in what argument(s) it accepts.
133
+ */
134
+ export declare function divUp(a: size_t, b: any): size_t;
135
+ export declare function dumpInputArray(argument: InputArray): String;
136
+ export declare function dumpInputArrayOfArrays(argument: InputArrayOfArrays): String;
137
+ export declare function dumpInputOutputArray(argument: InputOutputArray): String;
138
+ export declare function dumpInputOutputArrayOfArrays(argument: InputOutputArrayOfArrays): String;
139
+ /**
140
+ * By default the function prints information about the error to stderr, then it either stops if
141
+ * [cv::setBreakOnError()] had been called before or raises the exception. It is possible to alternate
142
+ * error processing by using [redirectError()].
143
+ *
144
+ * @param exc the exception raisen.
145
+ */
146
+ export declare function error(exc: any): void;
147
+ /**
148
+ * By default the function prints information about the error to stderr, then it either stops if
149
+ * [setBreakOnError()] had been called before or raises the exception. It is possible to alternate
150
+ * error processing by using [redirectError()].
151
+ *
152
+ * [CV_Error], [CV_Error_], [CV_Assert], [CV_DbgAssert]
153
+ *
154
+ * @param _code - error code (Error::Code)
155
+ *
156
+ * @param _err - error description
157
+ *
158
+ * @param _func - function name. Available only when the compiler supports getting it
159
+ *
160
+ * @param _file - source file name where the error has occurred
161
+ *
162
+ * @param _line - line number in the source file where the error has occurred
163
+ */
164
+ export declare function error(_code: int, _err: any, _func: any, _file: any, _line: int): void;
165
+ /**
166
+ * The function fastAtan2 calculates the full-range angle of an input 2D vector. The angle is measured
167
+ * in degrees and varies from 0 to 360 degrees. The accuracy is about 0.3 degrees.
168
+ *
169
+ * @param y y-coordinate of the vector.
170
+ *
171
+ * @param x x-coordinate of the vector.
172
+ */
173
+ export declare function fastAtan2(y: float, x: float): float;
174
+ /**
175
+ * The function deallocates the buffer allocated with fastMalloc . If NULL pointer is passed, the
176
+ * function does nothing. C version of the function clears the pointer *pptr* to avoid problems with
177
+ * double memory deallocation.
178
+ *
179
+ * @param ptr Pointer to the allocated buffer.
180
+ */
181
+ export declare function fastFree(ptr: any): void;
182
+ /**
183
+ * The function allocates the buffer of the specified size and returns it. When the buffer size is 16
184
+ * bytes or more, the returned buffer is aligned to 16 bytes.
185
+ *
186
+ * @param bufSize Allocated buffer size.
187
+ */
188
+ export declare function fastMalloc(bufSize: size_t): any;
189
+ export declare function forEach_impl(arg94: any, arg95: any, operation: any): any;
190
+ /**
191
+ * Returned value is raw cmake output including version control system revision, compiler version,
192
+ * compiler flags, enabled modules and third party libraries, etc. Output format depends on target
193
+ * architecture.
194
+ */
195
+ export declare function getBuildInformation(): any;
196
+ /**
197
+ * Returned value is a string containing space separated list of CPU features with following markers:
198
+ *
199
+ * no markers - baseline features
200
+ * prefix `*` - features enabled in dispatcher
201
+ * suffix `?` - features enabled but not available in HW
202
+ *
203
+ * Example: `SSE SSE2 SSE3 *SSE4.1 *SSE4.2 *FP16 *AVX *AVX2 *AVX512-SKX?`
204
+ */
205
+ export declare function getCPUFeaturesLine(): any;
206
+ /**
207
+ * The function returns the current number of CPU ticks on some architectures (such as x86, x64,
208
+ * PowerPC). On other platforms the function is equivalent to getTickCount. It can also be used for
209
+ * very accurate time measurements, as well as for [RNG] initialization. Note that in case of multi-CPU
210
+ * systems a thread, from which getCPUTickCount is called, can be suspended and resumed at another CPU
211
+ * with its own counter. So, theoretically (and practically) the subsequent calls to the function do
212
+ * not necessary return the monotonously increasing values. Also, since a modern CPU varies the CPU
213
+ * frequency depending on the load, the number of CPU clocks spent in some code cannot be directly
214
+ * converted to time units. Therefore, getTickCount is generally a preferable solution for measuring
215
+ * execution time.
216
+ */
217
+ export declare function getCPUTickCount(): int64;
218
+ export declare function getElemSize(type: int): size_t;
219
+ /**
220
+ * Returns empty string if feature is not defined
221
+ */
222
+ export declare function getHardwareFeatureName(feature: int): String;
223
+ export declare function getNumberOfCPUs(): int;
224
+ /**
225
+ * Always returns 1 if OpenCV is built without threading support.
226
+ *
227
+ * The exact meaning of return value depends on the threading framework used by OpenCV library:
228
+ *
229
+ * `TBB` - The number of threads, that OpenCV will try to use for parallel regions. If there is any
230
+ * tbb::thread_scheduler_init in user code conflicting with OpenCV, then function returns default
231
+ * number of threads used by TBB library.
232
+ * `OpenMP` - An upper bound on the number of threads that could be used to form a new team.
233
+ * `Concurrency` - The number of threads, that OpenCV will try to use for parallel regions.
234
+ * `GCD` - Unsupported; returns the GCD thread pool limit (512) for compatibility.
235
+ * `C=` - The number of threads, that OpenCV will try to use for parallel regions, if before called
236
+ * setNumThreads with threads > 0, otherwise returns the number of logical CPUs, available for the
237
+ * process.
238
+ *
239
+ * [setNumThreads], [getThreadNum]
240
+ */
241
+ export declare function getNumThreads(): int;
242
+ /**
243
+ * The exact meaning of the return value depends on the threading framework used by OpenCV library:
244
+ *
245
+ * `TBB` - Unsupported with current 4.1 TBB release. Maybe will be supported in future.
246
+ * `OpenMP` - The thread number, within the current team, of the calling thread.
247
+ * `Concurrency` - An ID for the virtual processor that the current context is executing on (0 for
248
+ * master thread and unique number for others, but not necessary 1,2,3,...).
249
+ * `GCD` - System calling thread's ID. Never returns 0 inside parallel region.
250
+ * `C=` - The index of the current parallel task.
251
+ *
252
+ * [setNumThreads], [getNumThreads]
253
+ */
254
+ export declare function getThreadNum(): int;
255
+ /**
256
+ * The function returns the number of ticks after the certain event (for example, when the machine was
257
+ * turned on). It can be used to initialize [RNG] or to measure a function execution time by reading
258
+ * the tick count before and after the function call.
259
+ *
260
+ * [getTickFrequency], [TickMeter]
261
+ */
262
+ export declare function getTickCount(): int64;
263
+ /**
264
+ * The function returns the number of ticks per second. That is, the following code computes the
265
+ * execution time in seconds:
266
+ *
267
+ * ```cpp
268
+ * double t = (double)getTickCount();
269
+ * // do something ...
270
+ * t = ((double)getTickCount() - t)/getTickFrequency();
271
+ * ```
272
+ *
273
+ * [getTickCount], [TickMeter]
274
+ */
275
+ export declare function getTickFrequency(): double;
276
+ export declare function getVersionMajor(): int;
277
+ export declare function getVersionMinor(): int;
278
+ export declare function getVersionRevision(): int;
279
+ /**
280
+ * For example "3.4.1-dev".
281
+ *
282
+ * getMajorVersion, getMinorVersion, getRevisionVersion
283
+ */
284
+ export declare function getVersionString(): String;
285
+ export declare function glob(pattern: String, result: any, recursive?: bool): void;
286
+ /**
287
+ * proxy for hal::LU
288
+ */
289
+ export declare function LU(A: any, astep: size_t, m: int, b: any, bstep: size_t, n: int): int;
290
+ /**
291
+ * proxy for hal::LU
292
+ */
293
+ export declare function LU(A: any, astep: size_t, m: int, b: any, bstep: size_t, n: int): int;
294
+ export declare function normInf(arg96: any, arg97: any, a: any, n: int): any;
295
+ export declare function normInf(arg98: any, arg99: any, a: any, b: any, n: int): any;
296
+ export declare function normL1(arg100: any, arg101: any, a: any, n: int): any;
297
+ export declare function normL1(arg102: any, arg103: any, a: any, b: any, n: int): any;
298
+ export declare function normL1(a: any, b: any, n: int): float;
299
+ export declare function normL1(a: uchar, b: uchar, n: int): uchar;
300
+ export declare function normL2Sqr(arg104: any, arg105: any, a: any, n: int): any;
301
+ export declare function normL2Sqr(arg106: any, arg107: any, a: any, b: any, n: int): any;
302
+ export declare function normL2Sqr(a: any, b: any, n: int): float;
303
+ export declare function parallel_for_(range: any, body: any, nstripes?: double): void;
304
+ export declare function parallel_for_(range: any, functor: any, nstripes?: double): void;
305
+ /**
306
+ * The function sets the new error handler, called from [cv::error()].
307
+ *
308
+ * the previous error handler
309
+ *
310
+ * @param errCallback the new error handler. If NULL, the default error handler is used.
311
+ *
312
+ * @param userdata the optional user data pointer, passed to the callback.
313
+ *
314
+ * @param prevUserdata the optional output parameter where the previous user data pointer is stored
315
+ */
316
+ export declare function redirectError(errCallback: ErrorCallback, userdata?: any, prevUserdata?: any): ErrorCallback;
317
+ /**
318
+ * Use this function instead of `ceil((float)a / b) * b` expressions.
319
+ *
320
+ * [divUp]
321
+ */
322
+ export declare function roundUp(a: int, b: any): int;
323
+ /**
324
+ * This is an overloaded member function, provided for convenience. It differs from the above function
325
+ * only in what argument(s) it accepts.
326
+ */
327
+ export declare function roundUp(a: size_t, b: any): size_t;
328
+ /**
329
+ * The function saturate_cast resembles the standard C++ cast operations, such as static_cast<T>() and
330
+ * others. It perform an efficient and accurate conversion from one primitive type to another (see the
331
+ * introduction chapter). saturate in the name means that when the input value v is out of the range of
332
+ * the target type, the result is not formed just by taking low bits of the input, but instead the
333
+ * value is clipped. For example:
334
+ *
335
+ * ```cpp
336
+ * uchar a = saturate_cast<uchar>(-100); // a = 0 (UCHAR_MIN)
337
+ * short b = saturate_cast<short>(33333.33333); // b = 32767 (SHRT_MAX)
338
+ * ```
339
+ *
340
+ * Such clipping is done when the target type is unsigned char , signed char , unsigned short or
341
+ * signed short . For 32-bit integers, no clipping is done.
342
+ *
343
+ * When the parameter is a floating-point value and the target type is an integer (8-, 16- or 32-bit),
344
+ * the floating-point value is first rounded to the nearest integer and then clipped if needed (when
345
+ * the target type is 8- or 16-bit).
346
+ *
347
+ * This operation is used in the simplest or most complex image processing functions in OpenCV.
348
+ *
349
+ * [add], [subtract], [multiply], [divide], [Mat::convertTo]
350
+ *
351
+ * @param v Function parameter.
352
+ */
353
+ export declare function saturate_cast(arg108: any, v: uchar): uchar;
354
+ /**
355
+ * This is an overloaded member function, provided for convenience. It differs from the above function
356
+ * only in what argument(s) it accepts.
357
+ */
358
+ export declare function saturate_cast(arg109: any, v: schar): schar;
359
+ /**
360
+ * This is an overloaded member function, provided for convenience. It differs from the above function
361
+ * only in what argument(s) it accepts.
362
+ */
363
+ export declare function saturate_cast(arg110: any, v: ushort): ushort;
364
+ /**
365
+ * This is an overloaded member function, provided for convenience. It differs from the above function
366
+ * only in what argument(s) it accepts.
367
+ */
368
+ export declare function saturate_cast(arg111: any, v: short): any;
369
+ /**
370
+ * This is an overloaded member function, provided for convenience. It differs from the above function
371
+ * only in what argument(s) it accepts.
372
+ */
373
+ export declare function saturate_cast(arg112: any, v: unsigned): any;
374
+ /**
375
+ * This is an overloaded member function, provided for convenience. It differs from the above function
376
+ * only in what argument(s) it accepts.
377
+ */
378
+ export declare function saturate_cast(arg113: any, v: int): any;
379
+ /**
380
+ * This is an overloaded member function, provided for convenience. It differs from the above function
381
+ * only in what argument(s) it accepts.
382
+ */
383
+ export declare function saturate_cast(arg114: any, v: float): any;
384
+ /**
385
+ * This is an overloaded member function, provided for convenience. It differs from the above function
386
+ * only in what argument(s) it accepts.
387
+ */
388
+ export declare function saturate_cast(arg115: any, v: double): any;
389
+ /**
390
+ * This is an overloaded member function, provided for convenience. It differs from the above function
391
+ * only in what argument(s) it accepts.
392
+ */
393
+ export declare function saturate_cast(arg116: any, v: int64): int64;
394
+ /**
395
+ * This is an overloaded member function, provided for convenience. It differs from the above function
396
+ * only in what argument(s) it accepts.
397
+ */
398
+ export declare function saturate_cast(arg117: any, v: uint64): uint64;
399
+ /**
400
+ * This is an overloaded member function, provided for convenience. It differs from the above function
401
+ * only in what argument(s) it accepts.
402
+ */
403
+ export declare function saturate_cast(arg118: any, v: float16_t): any;
404
+ /**
405
+ * When the break-on-error mode is set, the default error handler issues a hardware exception, which
406
+ * can make debugging more convenient.
407
+ *
408
+ * the previous state
409
+ */
410
+ export declare function setBreakOnError(flag: bool): bool;
411
+ /**
412
+ * If threads == 0, OpenCV will disable threading optimizations and run all it's functions
413
+ * sequentially. Passing threads < 0 will reset threads number to system default. This function must be
414
+ * called outside of parallel region.
415
+ *
416
+ * OpenCV will try to run its functions with specified threads number, but some behaviour differs from
417
+ * framework:
418
+ *
419
+ * `TBB` - User-defined parallel constructions will run with the same threads number, if another is not
420
+ * specified. If later on user creates his own scheduler, OpenCV will use it.
421
+ * `OpenMP` - No special defined behaviour.
422
+ * `Concurrency` - If threads == 1, OpenCV will disable threading optimizations and run its functions
423
+ * sequentially.
424
+ * `GCD` - Supports only values <= 0.
425
+ * `C=` - No special defined behaviour.
426
+ *
427
+ * [getNumThreads], [getThreadNum]
428
+ *
429
+ * @param nthreads Number of threads used by OpenCV.
430
+ */
431
+ export declare function setNumThreads(nthreads: int): void;
432
+ /**
433
+ * The function can be used to dynamically turn on and off optimized dispatched code (code that uses
434
+ * SSE4.2, AVX/AVX2, and other instructions on the platforms that support it). It sets a global flag
435
+ * that is further checked by OpenCV functions. Since the flag is not checked in the inner OpenCV
436
+ * loops, it is only safe to call the function on the very top level in your application where you can
437
+ * be sure that no other OpenCV function is currently executed.
438
+ *
439
+ * By default, the optimized code is enabled unless you disable it in CMake. The current status can be
440
+ * retrieved using useOptimized.
441
+ *
442
+ * @param onoff The boolean flag specifying whether the optimized code should be used (onoff=true) or
443
+ * not (onoff=false).
444
+ */
445
+ export declare function setUseOptimized(onoff: bool): void;
446
+ export declare function tempfile(suffix?: any): String;
447
+ export declare function testAsyncArray(argument: InputArray): AsyncArray;
448
+ export declare function testAsyncException(): AsyncArray;
449
+ /**
450
+ * The function returns true if the optimized code is enabled. Otherwise, it returns false.
451
+ */
452
+ export declare function useOptimized(): bool;
453
+ export declare const CPU_MMX: CpuFeatures;
454
+ export declare const CPU_SSE: CpuFeatures;
455
+ export declare const CPU_SSE2: CpuFeatures;
456
+ export declare const CPU_SSE3: CpuFeatures;
457
+ export declare const CPU_SSSE3: CpuFeatures;
458
+ export declare const CPU_SSE4_1: CpuFeatures;
459
+ export declare const CPU_SSE4_2: CpuFeatures;
460
+ export declare const CPU_POPCNT: CpuFeatures;
461
+ export declare const CPU_FP16: CpuFeatures;
462
+ export declare const CPU_AVX: CpuFeatures;
463
+ export declare const CPU_AVX2: CpuFeatures;
464
+ export declare const CPU_FMA3: CpuFeatures;
465
+ export declare const CPU_AVX_512F: CpuFeatures;
466
+ export declare const CPU_AVX_512BW: CpuFeatures;
467
+ export declare const CPU_AVX_512CD: CpuFeatures;
468
+ export declare const CPU_AVX_512DQ: CpuFeatures;
469
+ export declare const CPU_AVX_512ER: CpuFeatures;
470
+ export declare const CPU_AVX_512IFMA512: CpuFeatures;
471
+ export declare const CPU_AVX_512IFMA: CpuFeatures;
472
+ export declare const CPU_AVX_512PF: CpuFeatures;
473
+ export declare const CPU_AVX_512VBMI: CpuFeatures;
474
+ export declare const CPU_AVX_512VL: CpuFeatures;
475
+ export declare const CPU_AVX_512VBMI2: CpuFeatures;
476
+ export declare const CPU_AVX_512VNNI: CpuFeatures;
477
+ export declare const CPU_AVX_512BITALG: CpuFeatures;
478
+ export declare const CPU_AVX_512VPOPCNTDQ: CpuFeatures;
479
+ export declare const CPU_AVX_5124VNNIW: CpuFeatures;
480
+ export declare const CPU_AVX_5124FMAPS: CpuFeatures;
481
+ export declare const CPU_NEON: CpuFeatures;
482
+ export declare const CPU_VSX: CpuFeatures;
483
+ export declare const CPU_VSX3: CpuFeatures;
484
+ export declare const CPU_AVX512_SKX: CpuFeatures;
485
+ export declare const CPU_AVX512_COMMON: CpuFeatures;
486
+ export declare const CPU_AVX512_KNL: CpuFeatures;
487
+ export declare const CPU_AVX512_KNM: CpuFeatures;
488
+ export declare const CPU_AVX512_CNL: CpuFeatures;
489
+ export declare const CPU_AVX512_CEL: CpuFeatures;
490
+ export declare const CPU_AVX512_ICL: CpuFeatures;
491
+ export declare const CPU_MAX_FEATURE: CpuFeatures;
492
+ export declare const SORT_EVERY_ROW: SortFlags;
493
+ /**
494
+ * each matrix column is sorted independently; this flag and the previous one are mutually exclusive.
495
+ *
496
+ */
497
+ export declare const SORT_EVERY_COLUMN: SortFlags;
498
+ /**
499
+ * each matrix row is sorted in the ascending order.
500
+ *
501
+ */
502
+ export declare const SORT_ASCENDING: SortFlags;
503
+ /**
504
+ * each matrix row is sorted in the descending order; this flag and the previous one are also mutually
505
+ * exclusive.
506
+ *
507
+ */
508
+ export declare const SORT_DESCENDING: SortFlags;
509
+ export type CpuFeatures = any;
510
+ export type SortFlags = any;