@srsergio/taptapp-ar 1.0.0
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/README.md +62 -0
- package/dist/compiler/aframe.d.ts +1 -0
- package/dist/compiler/aframe.js +275 -0
- package/dist/compiler/compiler-base.d.ts +12 -0
- package/dist/compiler/compiler-base.js +165 -0
- package/dist/compiler/compiler.d.ts +9 -0
- package/dist/compiler/compiler.js +24 -0
- package/dist/compiler/compiler.worker.d.ts +1 -0
- package/dist/compiler/compiler.worker.js +28 -0
- package/dist/compiler/controller.d.ts +101 -0
- package/dist/compiler/controller.js +400 -0
- package/dist/compiler/controller.worker.d.ts +1 -0
- package/dist/compiler/controller.worker.js +61 -0
- package/dist/compiler/detector/crop-detector.d.ts +65 -0
- package/dist/compiler/detector/crop-detector.js +59 -0
- package/dist/compiler/detector/detector.d.ts +98 -0
- package/dist/compiler/detector/detector.js +1049 -0
- package/dist/compiler/detector/freak.d.ts +1 -0
- package/dist/compiler/detector/freak.js +89 -0
- package/dist/compiler/detector/kernels/cpu/binomialFilter.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/binomialFilter.js +51 -0
- package/dist/compiler/detector/kernels/cpu/buildExtremas.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/buildExtremas.js +89 -0
- package/dist/compiler/detector/kernels/cpu/computeExtremaAngles.d.ts +7 -0
- package/dist/compiler/detector/kernels/cpu/computeExtremaAngles.js +79 -0
- package/dist/compiler/detector/kernels/cpu/computeExtremaFreak.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/computeExtremaFreak.js +68 -0
- package/dist/compiler/detector/kernels/cpu/computeFreakDescriptors.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/computeFreakDescriptors.js +57 -0
- package/dist/compiler/detector/kernels/cpu/computeLocalization.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/computeLocalization.js +54 -0
- package/dist/compiler/detector/kernels/cpu/computeOrientationHistograms.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/computeOrientationHistograms.js +118 -0
- package/dist/compiler/detector/kernels/cpu/downsampleBilinear.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/downsampleBilinear.js +29 -0
- package/dist/compiler/detector/kernels/cpu/extremaReduction.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/extremaReduction.js +50 -0
- package/dist/compiler/detector/kernels/cpu/fakeShader.d.ts +20 -0
- package/dist/compiler/detector/kernels/cpu/fakeShader.js +80 -0
- package/dist/compiler/detector/kernels/cpu/index.d.ts +1 -0
- package/dist/compiler/detector/kernels/cpu/index.js +25 -0
- package/dist/compiler/detector/kernels/cpu/prune.d.ts +1 -0
- package/dist/compiler/detector/kernels/cpu/prune.js +103 -0
- package/dist/compiler/detector/kernels/cpu/smoothHistograms.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/smoothHistograms.js +47 -0
- package/dist/compiler/detector/kernels/cpu/upsampleBilinear.d.ts +6 -0
- package/dist/compiler/detector/kernels/cpu/upsampleBilinear.js +43 -0
- package/dist/compiler/detector/kernels/index.d.ts +1 -0
- package/dist/compiler/detector/kernels/index.js +2 -0
- package/dist/compiler/detector/kernels/webgl/binomialFilter.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/binomialFilter.js +67 -0
- package/dist/compiler/detector/kernels/webgl/buildExtremas.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/buildExtremas.js +101 -0
- package/dist/compiler/detector/kernels/webgl/computeExtremaAngles.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/computeExtremaAngles.js +78 -0
- package/dist/compiler/detector/kernels/webgl/computeExtremaFreak.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/computeExtremaFreak.js +86 -0
- package/dist/compiler/detector/kernels/webgl/computeFreakDescriptors.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/computeFreakDescriptors.js +52 -0
- package/dist/compiler/detector/kernels/webgl/computeLocalization.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/computeLocalization.js +58 -0
- package/dist/compiler/detector/kernels/webgl/computeOrientationHistograms.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/computeOrientationHistograms.js +116 -0
- package/dist/compiler/detector/kernels/webgl/downsampleBilinear.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/downsampleBilinear.js +46 -0
- package/dist/compiler/detector/kernels/webgl/extremaReduction.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/extremaReduction.js +48 -0
- package/dist/compiler/detector/kernels/webgl/index.d.ts +1 -0
- package/dist/compiler/detector/kernels/webgl/index.js +25 -0
- package/dist/compiler/detector/kernels/webgl/smoothHistograms.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/smoothHistograms.js +49 -0
- package/dist/compiler/detector/kernels/webgl/upsampleBilinear.d.ts +6 -0
- package/dist/compiler/detector/kernels/webgl/upsampleBilinear.js +56 -0
- package/dist/compiler/estimation/esimate-experiment.d.ts +5 -0
- package/dist/compiler/estimation/esimate-experiment.js +267 -0
- package/dist/compiler/estimation/estimate.d.ts +5 -0
- package/dist/compiler/estimation/estimate.js +51 -0
- package/dist/compiler/estimation/estimator.d.ts +13 -0
- package/dist/compiler/estimation/estimator.js +30 -0
- package/dist/compiler/estimation/refine-estimate-experiment.d.ts +6 -0
- package/dist/compiler/estimation/refine-estimate-experiment.js +429 -0
- package/dist/compiler/estimation/refine-estimate.d.ts +6 -0
- package/dist/compiler/estimation/refine-estimate.js +299 -0
- package/dist/compiler/estimation/utils.d.ts +10 -0
- package/dist/compiler/estimation/utils.js +80 -0
- package/dist/compiler/image-list.d.ts +13 -0
- package/dist/compiler/image-list.js +52 -0
- package/dist/compiler/index.d.ts +3 -0
- package/dist/compiler/index.js +10 -0
- package/dist/compiler/input-loader.d.ts +23 -0
- package/dist/compiler/input-loader.js +88 -0
- package/dist/compiler/matching/hamming-distance.d.ts +1 -0
- package/dist/compiler/matching/hamming-distance.js +20 -0
- package/dist/compiler/matching/hierarchical-clustering.d.ts +7 -0
- package/dist/compiler/matching/hierarchical-clustering.js +109 -0
- package/dist/compiler/matching/hough.d.ts +1 -0
- package/dist/compiler/matching/hough.js +169 -0
- package/dist/compiler/matching/matcher.d.ts +28 -0
- package/dist/compiler/matching/matcher.js +48 -0
- package/dist/compiler/matching/matching.d.ts +41 -0
- package/dist/compiler/matching/matching.js +197 -0
- package/dist/compiler/matching/ransacHomography.d.ts +1 -0
- package/dist/compiler/matching/ransacHomography.js +136 -0
- package/dist/compiler/offline-compiler.d.ts +10 -0
- package/dist/compiler/offline-compiler.js +450 -0
- package/dist/compiler/tensorflow-setup.d.ts +7 -0
- package/dist/compiler/tensorflow-setup.js +73 -0
- package/dist/compiler/three.d.ts +66 -0
- package/dist/compiler/three.js +310 -0
- package/dist/compiler/tracker/extract-utils.d.ts +1 -0
- package/dist/compiler/tracker/extract-utils.js +29 -0
- package/dist/compiler/tracker/extract.d.ts +4 -0
- package/dist/compiler/tracker/extract.js +349 -0
- package/dist/compiler/tracker/tracker.d.ts +38 -0
- package/dist/compiler/tracker/tracker.js +327 -0
- package/dist/compiler/utils/cumsum.d.ts +5 -0
- package/dist/compiler/utils/cumsum.js +39 -0
- package/dist/compiler/utils/geometry.d.ts +8 -0
- package/dist/compiler/utils/geometry.js +101 -0
- package/dist/compiler/utils/homography.d.ts +1 -0
- package/dist/compiler/utils/homography.js +138 -0
- package/dist/compiler/utils/images.d.ts +24 -0
- package/dist/compiler/utils/images.js +99 -0
- package/dist/compiler/utils/randomizer.d.ts +5 -0
- package/dist/compiler/utils/randomizer.js +25 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +7 -0
- package/dist/react/AREditor.d.ts +5 -0
- package/dist/react/AREditor.js +159 -0
- package/dist/react/ProgressDialog.d.ts +13 -0
- package/dist/react/ProgressDialog.js +57 -0
- package/dist/react/types.d.ts +22 -0
- package/dist/react/types.js +14 -0
- package/package.json +53 -0
- package/src/astro/ARScene.astro +59 -0
- package/src/astro/ARVideoTrigger.astro +73 -0
- package/src/astro/overlays/ErrorOverlay.astro +40 -0
- package/src/astro/overlays/LoadingOverlay.astro +28 -0
- package/src/astro/overlays/ScanningOverlay.astro +119 -0
- package/src/astro/scripts/ARScripts.astro +118 -0
- package/src/astro/styles/ARStyles.astro +147 -0
- package/src/compiler/aframe.js +343 -0
- package/src/compiler/compiler-base.js +195 -0
- package/src/compiler/compiler.js +25 -0
- package/src/compiler/compiler.worker.js +30 -0
- package/src/compiler/controller.js +473 -0
- package/src/compiler/controller.worker.js +77 -0
- package/src/compiler/detector/crop-detector.js +68 -0
- package/src/compiler/detector/detector.js +1130 -0
- package/src/compiler/detector/freak.js +91 -0
- package/src/compiler/detector/kernels/cpu/binomialFilter.js +59 -0
- package/src/compiler/detector/kernels/cpu/buildExtremas.js +108 -0
- package/src/compiler/detector/kernels/cpu/computeExtremaAngles.js +91 -0
- package/src/compiler/detector/kernels/cpu/computeExtremaFreak.js +92 -0
- package/src/compiler/detector/kernels/cpu/computeFreakDescriptors.js +68 -0
- package/src/compiler/detector/kernels/cpu/computeLocalization.js +71 -0
- package/src/compiler/detector/kernels/cpu/computeOrientationHistograms.js +141 -0
- package/src/compiler/detector/kernels/cpu/downsampleBilinear.js +33 -0
- package/src/compiler/detector/kernels/cpu/extremaReduction.js +53 -0
- package/src/compiler/detector/kernels/cpu/fakeShader.js +88 -0
- package/src/compiler/detector/kernels/cpu/index.js +26 -0
- package/src/compiler/detector/kernels/cpu/prune.js +114 -0
- package/src/compiler/detector/kernels/cpu/smoothHistograms.js +57 -0
- package/src/compiler/detector/kernels/cpu/upsampleBilinear.js +51 -0
- package/src/compiler/detector/kernels/index.js +2 -0
- package/src/compiler/detector/kernels/webgl/binomialFilter.js +72 -0
- package/src/compiler/detector/kernels/webgl/buildExtremas.js +109 -0
- package/src/compiler/detector/kernels/webgl/computeExtremaAngles.js +82 -0
- package/src/compiler/detector/kernels/webgl/computeExtremaFreak.js +105 -0
- package/src/compiler/detector/kernels/webgl/computeFreakDescriptors.js +56 -0
- package/src/compiler/detector/kernels/webgl/computeLocalization.js +70 -0
- package/src/compiler/detector/kernels/webgl/computeOrientationHistograms.js +129 -0
- package/src/compiler/detector/kernels/webgl/downsampleBilinear.js +50 -0
- package/src/compiler/detector/kernels/webgl/extremaReduction.js +50 -0
- package/src/compiler/detector/kernels/webgl/index.js +26 -0
- package/src/compiler/detector/kernels/webgl/smoothHistograms.js +53 -0
- package/src/compiler/detector/kernels/webgl/upsampleBilinear.js +62 -0
- package/src/compiler/estimation/esimate-experiment.js +316 -0
- package/src/compiler/estimation/estimate.js +67 -0
- package/src/compiler/estimation/estimator.js +34 -0
- package/src/compiler/estimation/refine-estimate-experiment.js +512 -0
- package/src/compiler/estimation/refine-estimate.js +365 -0
- package/src/compiler/estimation/utils.js +97 -0
- package/src/compiler/image-list.js +62 -0
- package/src/compiler/index.js +13 -0
- package/src/compiler/input-loader.js +107 -0
- package/src/compiler/matching/hamming-distance.js +23 -0
- package/src/compiler/matching/hierarchical-clustering.js +131 -0
- package/src/compiler/matching/hough.js +206 -0
- package/src/compiler/matching/matcher.js +59 -0
- package/src/compiler/matching/matching.js +237 -0
- package/src/compiler/matching/ransacHomography.js +192 -0
- package/src/compiler/offline-compiler.js +553 -0
- package/src/compiler/tensorflow-setup.js +88 -0
- package/src/compiler/three.js +368 -0
- package/src/compiler/tracker/extract-utils.js +34 -0
- package/src/compiler/tracker/extract.js +419 -0
- package/src/compiler/tracker/tracker.js +397 -0
- package/src/compiler/utils/cumsum.js +40 -0
- package/src/compiler/utils/geometry.js +114 -0
- package/src/compiler/utils/homography.js +150 -0
- package/src/compiler/utils/images.js +111 -0
- package/src/compiler/utils/randomizer.js +29 -0
- package/src/index.ts +8 -0
- package/src/react/AREditor.tsx +394 -0
- package/src/react/ProgressDialog.tsx +185 -0
- package/src/react/types.ts +35 -0
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import { Matrix, inverse } from "ml-matrix";
|
|
2
|
+
import { createRandomizer } from "../utils/randomizer.js";
|
|
3
|
+
import {
|
|
4
|
+
quadrilateralConvex,
|
|
5
|
+
matrixInverse33,
|
|
6
|
+
smallestTriangleArea,
|
|
7
|
+
multiplyPointHomographyInhomogenous,
|
|
8
|
+
checkThreePointsConsistent,
|
|
9
|
+
checkFourPointsConsistent,
|
|
10
|
+
determinant,
|
|
11
|
+
} from "../utils/geometry.js";
|
|
12
|
+
import { solveHomography } from "../utils/homography.js";
|
|
13
|
+
|
|
14
|
+
const CAUCHY_SCALE = 0.01;
|
|
15
|
+
const CHUNK_SIZE = 10;
|
|
16
|
+
const NUM_HYPOTHESES = 20;
|
|
17
|
+
const NUM_HYPOTHESES_QUICK = 10;
|
|
18
|
+
|
|
19
|
+
// Using RANSAC to estimate homography
|
|
20
|
+
const computeHomography = (options) => {
|
|
21
|
+
const { srcPoints, dstPoints, keyframe, quickMode } = options;
|
|
22
|
+
|
|
23
|
+
// testPoints is four corners of keyframe
|
|
24
|
+
const testPoints = [
|
|
25
|
+
[0, 0],
|
|
26
|
+
[keyframe.width, 0],
|
|
27
|
+
[keyframe.width, keyframe.height],
|
|
28
|
+
[0, keyframe.height],
|
|
29
|
+
];
|
|
30
|
+
|
|
31
|
+
const sampleSize = 4; // use four points to compute homography
|
|
32
|
+
if (srcPoints.length < sampleSize) return null;
|
|
33
|
+
|
|
34
|
+
const scale = CAUCHY_SCALE;
|
|
35
|
+
const oneOverScale2 = 1.0 / (scale * scale);
|
|
36
|
+
const chuckSize = Math.min(CHUNK_SIZE, srcPoints.length);
|
|
37
|
+
|
|
38
|
+
const randomizer = createRandomizer();
|
|
39
|
+
|
|
40
|
+
const perm = [];
|
|
41
|
+
for (let i = 0; i < srcPoints.length; i++) {
|
|
42
|
+
perm[i] = i;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
randomizer.arrayShuffle({ arr: perm, sampleSize: perm.length });
|
|
46
|
+
|
|
47
|
+
const numHypothesis = quickMode ? NUM_HYPOTHESES_QUICK : NUM_HYPOTHESES;
|
|
48
|
+
const maxTrials = numHypothesis * 2;
|
|
49
|
+
|
|
50
|
+
// build numerous hypotheses by randoming draw four points
|
|
51
|
+
// TODO: optimize: if number of points is less than certain number, can brute force all combinations
|
|
52
|
+
let trial = 0;
|
|
53
|
+
const Hs = [];
|
|
54
|
+
while (trial < maxTrials && Hs.length < numHypothesis) {
|
|
55
|
+
trial += 1;
|
|
56
|
+
|
|
57
|
+
randomizer.arrayShuffle({ arr: perm, sampleSize: sampleSize });
|
|
58
|
+
|
|
59
|
+
// their relative positions match each other
|
|
60
|
+
if (
|
|
61
|
+
!checkFourPointsConsistent(
|
|
62
|
+
srcPoints[perm[0]],
|
|
63
|
+
srcPoints[perm[1]],
|
|
64
|
+
srcPoints[perm[2]],
|
|
65
|
+
srcPoints[perm[3]],
|
|
66
|
+
dstPoints[perm[0]],
|
|
67
|
+
dstPoints[perm[1]],
|
|
68
|
+
dstPoints[perm[2]],
|
|
69
|
+
dstPoints[perm[3]],
|
|
70
|
+
)
|
|
71
|
+
) {
|
|
72
|
+
continue;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
const H = solveHomography(
|
|
76
|
+
[srcPoints[perm[0]], srcPoints[perm[1]], srcPoints[perm[2]], srcPoints[perm[3]]],
|
|
77
|
+
[dstPoints[perm[0]], dstPoints[perm[1]], dstPoints[perm[2]], dstPoints[perm[3]]],
|
|
78
|
+
);
|
|
79
|
+
if (H === null) continue;
|
|
80
|
+
|
|
81
|
+
if (!_checkHomographyPointsGeometricallyConsistent({ H, testPoints })) {
|
|
82
|
+
continue;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
Hs.push(H);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
if (Hs.length === 0) return null;
|
|
89
|
+
|
|
90
|
+
// pick the best hypothesis
|
|
91
|
+
const hypotheses = [];
|
|
92
|
+
for (let i = 0; i < Hs.length; i++) {
|
|
93
|
+
hypotheses.push({
|
|
94
|
+
H: Hs[i],
|
|
95
|
+
cost: 0,
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
let curChuckSize = chuckSize;
|
|
100
|
+
for (let i = 0; i < srcPoints.length && hypotheses.length > 2; i += curChuckSize) {
|
|
101
|
+
curChuckSize = Math.min(chuckSize, srcPoints.length - i);
|
|
102
|
+
let chuckEnd = i + curChuckSize;
|
|
103
|
+
|
|
104
|
+
for (let j = 0; j < hypotheses.length; j++) {
|
|
105
|
+
for (let k = i; k < chuckEnd; k++) {
|
|
106
|
+
const cost = _cauchyProjectiveReprojectionCost({
|
|
107
|
+
H: hypotheses[j].H,
|
|
108
|
+
srcPoint: srcPoints[k],
|
|
109
|
+
dstPoint: dstPoints[k],
|
|
110
|
+
oneOverScale2,
|
|
111
|
+
});
|
|
112
|
+
hypotheses[j].cost += cost;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
hypotheses.sort((h1, h2) => {
|
|
117
|
+
return h1.cost - h2.cost;
|
|
118
|
+
});
|
|
119
|
+
hypotheses.splice(-Math.floor((hypotheses.length + 1) / 2)); // keep the best half
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
let finalH = null;
|
|
123
|
+
for (let i = 0; i < hypotheses.length; i++) {
|
|
124
|
+
const H = _normalizeHomography({ inH: hypotheses[i].H });
|
|
125
|
+
if (_checkHeuristics({ H: H, testPoints, keyframe })) {
|
|
126
|
+
finalH = H;
|
|
127
|
+
break;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
return finalH;
|
|
131
|
+
};
|
|
132
|
+
|
|
133
|
+
const _checkHeuristics = ({ H, testPoints, keyframe }) => {
|
|
134
|
+
const HInv = matrixInverse33(H, 0.00001);
|
|
135
|
+
if (HInv === null) return false;
|
|
136
|
+
|
|
137
|
+
const mp = [];
|
|
138
|
+
for (let i = 0; i < testPoints.length; i++) {
|
|
139
|
+
// 4 test points, corner of keyframe
|
|
140
|
+
mp.push(multiplyPointHomographyInhomogenous(testPoints[i], HInv));
|
|
141
|
+
}
|
|
142
|
+
const smallArea = smallestTriangleArea(mp[0], mp[1], mp[2], mp[3]);
|
|
143
|
+
|
|
144
|
+
if (smallArea < keyframe.width * keyframe.height * 0.0001) return false;
|
|
145
|
+
|
|
146
|
+
if (!quadrilateralConvex(mp[0], mp[1], mp[2], mp[3])) return false;
|
|
147
|
+
|
|
148
|
+
return true;
|
|
149
|
+
};
|
|
150
|
+
|
|
151
|
+
const _normalizeHomography = ({ inH }) => {
|
|
152
|
+
const oneOver = 1.0 / inH[8];
|
|
153
|
+
|
|
154
|
+
const H = [];
|
|
155
|
+
for (let i = 0; i < 8; i++) {
|
|
156
|
+
H[i] = inH[i] * oneOver;
|
|
157
|
+
}
|
|
158
|
+
H[8] = 1.0;
|
|
159
|
+
return H;
|
|
160
|
+
};
|
|
161
|
+
|
|
162
|
+
const _cauchyProjectiveReprojectionCost = ({ H, srcPoint, dstPoint, oneOverScale2 }) => {
|
|
163
|
+
const x = multiplyPointHomographyInhomogenous(srcPoint, H);
|
|
164
|
+
const f = [x[0] - dstPoint[0], x[1] - dstPoint[1]];
|
|
165
|
+
return Math.log(1 + (f[0] * f[0] + f[1] * f[1]) * oneOverScale2);
|
|
166
|
+
};
|
|
167
|
+
|
|
168
|
+
const _checkHomographyPointsGeometricallyConsistent = ({ H, testPoints }) => {
|
|
169
|
+
const mappedPoints = [];
|
|
170
|
+
for (let i = 0; i < testPoints.length; i++) {
|
|
171
|
+
mappedPoints[i] = multiplyPointHomographyInhomogenous(testPoints[i], H);
|
|
172
|
+
}
|
|
173
|
+
for (let i = 0; i < testPoints.length; i++) {
|
|
174
|
+
const i1 = i;
|
|
175
|
+
const i2 = (i + 1) % testPoints.length;
|
|
176
|
+
const i3 = (i + 2) % testPoints.length;
|
|
177
|
+
if (
|
|
178
|
+
!checkThreePointsConsistent(
|
|
179
|
+
testPoints[i1],
|
|
180
|
+
testPoints[i2],
|
|
181
|
+
testPoints[i3],
|
|
182
|
+
mappedPoints[i1],
|
|
183
|
+
mappedPoints[i2],
|
|
184
|
+
mappedPoints[i3],
|
|
185
|
+
)
|
|
186
|
+
)
|
|
187
|
+
return false;
|
|
188
|
+
}
|
|
189
|
+
return true;
|
|
190
|
+
};
|
|
191
|
+
|
|
192
|
+
export { computeHomography };
|