Mercurial > hg > match-vamp
comparison src/Finder.h @ 147:3673e2dae6a7 structure
Factor out getBestEdgeCost
author | Chris Cannam |
---|---|
date | Thu, 22 Jan 2015 12:04:44 +0000 |
parents | c665173b3a33 |
children | 4159f6b71942 |
comparison
equal
deleted
inserted
replaced
146:214b72d55796 | 147:3673e2dae6a7 |
---|---|
35 * otherwise to be ignored. d1 and d2 are feature frame counts for | 35 * otherwise to be ignored. d1 and d2 are feature frame counts for |
36 * matchers 1 and 2 respectively. If this is not called, the full | 36 * matchers 1 and 2 respectively. If this is not called, the full |
37 * duration of each input will be considered. | 37 * duration of each input will be considered. |
38 */ | 38 */ |
39 void setDurations(int d1, int d2); | 39 void setDurations(int d1, int d2); |
40 | 40 |
41 /** | |
42 * Find the location and cost of the cheapest path cost within the | |
43 * final row and column of the search area, given that the area | |
44 * extends as far as the point at (row, col). This is used by | |
45 * getExpandDirection and can also be used, for example, to | |
46 * determine the current best estimate alignment for a frame we | |
47 * have just reached. | |
48 */ | |
49 void getBestEdgeCost(int row, int col, | |
50 int &bestRow, int &bestCol, | |
51 double &bestCost); | |
52 | |
53 /** | |
54 * Calculate which direction to expand the search area in, given | |
55 * that so far it extends as far as the point at (row, col). | |
56 */ | |
41 Matcher::Advance getExpandDirection(int row, int col); | 57 Matcher::Advance getExpandDirection(int row, int col); |
42 | 58 |
43 /** Calculates a rectangle of the path cost matrix so that the | 59 /** Calculates a rectangle of the path cost matrix so that the |
44 * minimum cost path between the bottom left and top right | 60 * minimum cost path between the bottom left and top right |
45 * corners can be computed. Caches previous values to avoid | 61 * corners can be computed. Caches previous values to avoid |
82 }; | 98 }; |
83 ErrorPosition checkPathCostMatrix(); | 99 ErrorPosition checkPathCostMatrix(); |
84 void checkAndReport(); | 100 void checkAndReport(); |
85 #endif | 101 #endif |
86 | 102 |
87 Matcher *m_m; | 103 Matcher *m_m; // I do not own this |
104 | |
88 int m_duration1; | 105 int m_duration1; |
89 int m_duration2; | 106 int m_duration2; |
90 }; // class Finder | 107 }; |
91 | 108 |
92 #endif | 109 #endif |