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

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

Added original make3d

File size: 870 bytes
Line 
1%       By Philip Torr 2002
2%       copyright Microsoft Corp.
3
4%a function to display the images matches
5%matches, figure, display_numbers
6function f1 = torr_display_matches(matches,display_numbers,f1)
7
8
9
10if nargin < 2
11    display_numbers = 0;
12end
13
14if nargin < 3
15    m1 = max(max(matches));
16    m2 = min(min(matches));
17    m2 = -m2;
18    g = max(m1,m2);
19    f1 = figure
20    axis([-g g -g g])   
21else
22    figure(f1)
23    hold on
24end
25
26x1 = matches(:,1);
27y1 = matches(:,2);
28x2 = matches(:,3);
29y2 = matches(:,4);
30
31u1 = x2 - x1;
32v1 = y2 - y1;
33
34
35
36plot (matches(:,1), matches(:,2),'r+');
37hold on
38plot (matches(:,3), matches(:,4),'r+');
39if display_numbers
40    mat_index1 = 1:length(matches);
41    mat_index1 = mat_index1';
42    mat_index = num2str(mat_index1);
43    text(matches(:,1), matches(:,2),mat_index)
44end
45
46quiver(x1, y1, u1, v1, 0)
47hold off
Note: See TracBrowser for help on using the repository browser.