tesseract-doxygen/ccutil/helpers.h File Reference
#include <stdio.h>
#include <string.h>
Go to the source code of this file.
Functions |
void | chomp_string (char *str) |
void | SkipNewline (FILE *file) |
int | sort_floats (const void *arg1, const void *arg2) |
int | RoundUp (int n, int block_size) |
template<typename T > |
T | ClipToRange (const T &x, const T &lower_bound, const T &upper_bound) |
template<typename T1 , typename T2 > |
void | UpdateRange (const T1 &x, T2 *lower_bound, T2 *upper_bound) |
template<typename T1 , typename T2 > |
void | UpdateRange (const T1 &x_lo, const T1 &x_hi, T2 *lower_bound, T2 *upper_bound) |
int | Modulo (int a, int b) |
int | DivRounded (int a, int b) |
void | ReverseN (void *ptr, int num_bytes) |
void | Reverse16 (void *ptr) |
void | Reverse32 (void *ptr) |
void | Reverse64 (void *ptr) |
Function Documentation
void chomp_string |
( |
char * |
str |
) |
[inline] |
template<typename T >
T ClipToRange |
( |
const T & |
x, |
|
|
const T & |
lower_bound, |
|
|
const T & |
upper_bound | |
|
) |
| | [inline] |
int DivRounded |
( |
int |
a, |
|
|
int |
b | |
|
) |
| | [inline] |
int Modulo |
( |
int |
a, |
|
|
int |
b | |
|
) |
| | [inline] |
void Reverse16 |
( |
void * |
ptr |
) |
[inline] |
void Reverse32 |
( |
void * |
ptr |
) |
[inline] |
void Reverse64 |
( |
void * |
ptr |
) |
[inline] |
void ReverseN |
( |
void * |
ptr, |
|
|
int |
num_bytes | |
|
) |
| | [inline] |
int RoundUp |
( |
int |
n, |
|
|
int |
block_size | |
|
) |
| | [inline] |
void SkipNewline |
( |
FILE * |
file |
) |
[inline] |
int sort_floats |
( |
const void * |
arg1, |
|
|
const void * |
arg2 | |
|
) |
| | [inline] |
template<typename T1 , typename T2 >
void UpdateRange |
( |
const T1 & |
x_lo, |
|
|
const T1 & |
x_hi, |
|
|
T2 * |
lower_bound, |
|
|
T2 * |
upper_bound | |
|
) |
| | [inline] |
template<typename T1 , typename T2 >
void UpdateRange |
( |
const T1 & |
x, |
|
|
T2 * |
lower_bound, |
|
|
T2 * |
upper_bound | |
|
) |
| | [inline] |