#include <altlist.h>
List of all members.
Detailed Description
Definition at line 30 of file altlist.h.
Constructor & Destructor Documentation
tesseract::AltList::AltList |
( |
int |
max_alt | ) |
[explicit] |
tesseract::AltList::~AltList |
( |
| ) |
[virtual] |
Member Function Documentation
int tesseract::AltList::AltCost |
( |
int |
alt_idx | ) |
const [inline] |
int tesseract::AltList::AltCount |
( |
| ) |
const [inline] |
double tesseract::AltList::AltProb |
( |
int |
alt_idx | ) |
const [inline] |
void* tesseract::AltList::AltTag |
( |
int |
alt_idx | ) |
const [inline] |
int tesseract::AltList::BestCost |
( |
int * |
best_alt | ) |
const |
Definition at line 45 of file altlist.cpp.
{
if (alt_cnt_ <= 0) {
(*best_alt) = -1;
return -1;
}
int best_alt_idx = 0;
for (int alt_idx = 1; alt_idx < alt_cnt_; alt_idx++) {
if (alt_cost_[alt_idx] < alt_cost_[best_alt_idx]) {
best_alt_idx = alt_idx;
}
}
(*best_alt) = best_alt_idx;
return alt_cost_[best_alt_idx];
}
virtual void tesseract::AltList::Sort |
( |
| ) |
[pure virtual] |
Member Data Documentation
The documentation for this class was generated from the following files: