Tesseract 3.02

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | Public Attributes
tesseract::ShapeRating Struct Reference

`#include <shapeclassifier.h>`

List of all members.

## Public Member Functions

| ShapeRating ()
| ShapeRating (int s, float r)

## Static Public Member Functions

static int | SortDescendingRating (const void *t1, const void *t2)

## Public Attributes

int | shape_id
float | rating
float | raw
float | font

## Detailed Description

Definition at line 36 of file shapeclassifier.h.

## Constructor & Destructor Documentation

tesseract::ShapeRating::ShapeRating | ( |  | ) |

inline

Definition at line 37 of file shapeclassifier.h.

: shape_id(0), rating(0.0f), raw(0.0f), font(0.0f) {}

tesseract::ShapeRating::ShapeRating | ( | int | s,
|  | float | r
| ) |  |

inline

Definition at line 38 of file shapeclassifier.h.

: shape_id(s), rating(r), raw(1.0f), font(0.0f) {}

## Member Function Documentation

static int tesseract::ShapeRating::SortDescendingRating | ( | const void * | t1,
|  | const void * | t2
| ) |  |

inlinestatic

Definition at line 42 of file shapeclassifier.h.

{
const ShapeRating* a = reinterpret_cast<const ShapeRating *>(t1);
const ShapeRating* b = reinterpret_cast<const ShapeRating *>(t2);
if (a->rating > b->rating) {
return -1;
} else if (a->rating < b->rating) {
return 1;
} else {
return a->shape_id - b->shape_id;
}
}

## Member Data Documentation

float tesseract::ShapeRating::font

Definition at line 62 of file shapeclassifier.h.

float tesseract::ShapeRating::rating

Definition at line 58 of file shapeclassifier.h.

float tesseract::ShapeRating::raw

Definition at line 60 of file shapeclassifier.h.

int tesseract::ShapeRating::shape_id

Definition at line 55 of file shapeclassifier.h.

The documentation for this struct was generated from the following file:

- /mnt/data/src/tesseract-ocr/classify/shapeclassifier.h