20 #ifndef TESSERACT_TRAINING_DEGRADEIMAGE_H_ 21 #define TESSERACT_TRAINING_DEGRADEIMAGE_H_ 23 #include "allheaders.h" 35 struct Pix*
DegradeImage(
struct Pix* input,
int exposure, TRand* randomizer,
44 bool white_noise,
bool smooth_noise,
bool blur,
45 int box_reduction, TRand* randomizer,
57 float** im_coeffs,
float** box_coeffs);
61 #endif // TESSERACT_TRAINING_DEGRADEIMAGE_H_
Pix * PrepareDistortedPix(const Pix *pix, bool perspective, bool invert, bool white_noise, bool smooth_noise, bool blur, int box_reduction, TRand *randomizer, GenericVector< TBOX > *boxes)
Pix * DegradeImage(Pix *input, int exposure, TRand *randomizer, float *rotation)
void GeneratePerspectiveDistortion(int width, int height, TRand *randomizer, Pix **pix, GenericVector< TBOX > *boxes)
int ProjectiveCoeffs(int width, int height, TRand *randomizer, float **im_coeffs, float **box_coeffs)