source: proiecte/pmake3d/make3d_original/Make3dSingleImageStanford_version0.1/third_party/torr/torr_estf.m @ 37

Last change on this file since 37 was 37, checked in by (none), 14 years ago

Added original make3d

File size: 813 bytes
Line 
1%       By Philip Torr 2002
2%       copyright Microsoft Corp.
3% estimate fundamental matrix from perfect points??
4
5function f = torr_estf(x1,y1,x2,y2, no_matches,m3)
6%disp('This just does calculation of perfect data,for test')
7%disp('Use estf otherwise')
8
9%for(i = 1:no_matches)
10   
11   A(:,1) = x1(:).* x2(:);
12   A(:,2) = y1(:).* x2(:);
13   A(:,3) = m3* x2(:);
14   
15   A(:,4) = x1(:).* y2(:);
16   A(:,5) = y1(:).* y2(:);
17   A(:,6) = m3* y2(:);
18   
19   A(:,7) = x1(:).* m3;
20   A(:,8) = y1(:).* m3;
21   A(:,9) = m3* m3;
22   
23   
24%end
25
26
27% (x2 y2 m3) F (x1 y1 m3)'
28%  (image 2) F ( image 1)'
29
30
31%est_F = [v(1) v(2) v(3); v(4) v(5) v(6); v(7) v(8) v(9)];
32
33f = torr_ls(A);
34
35%algebraic residuals
36%r = A * v;
37
38
39%disp('This just does calculation of perfect data,for test')
40%disp('Use estf otherwise')
Note: See TracBrowser for help on using the repository browser.