PIXROW Class Reference

#include <charcut.h>

Inheritance diagram for PIXROW:
ELIST_LINK

List of all members.

Public Member Functions

 PIXROW ()
 PIXROW (inT16 pos, inT16 count, PBLOB *blob)
 ~PIXROW ()
void plot (ScrollView *fd) const
TBOX bounding_box () const
bool bad_box (int xsize, int ysize) const
void contract (IMAGELINE *imlines, inT16 x_offset, inT16 foreground_colour)
BOOL8 extend (IMAGELINE *imlines, TBOX &imbox, PIXROW *prev, PIXROW *next, inT16 foreground_colour)
void char_clip_image (IMAGELINE *imlines, TBOX &im_box, ROW *row, IMAGE &clip_image, float &baseline_pos)

Public Attributes

inT16 row_offset
 y coord of min[0]
inT16 row_count
 length of arrays
inT16min
 array of min x
inT16max
 array of max x

Detailed Description

This class describes the pixels occupied by a blob. It uses two arrays, (min and max), each with one element per row, to identify the min and max x coordinates of the black pixels in the character on that row of the image. The number of rows used to describe the blob is held in row_count - note that some rows may be unoccupied - signified by max < min. The page coordinate of the row defined by min[0] and max[0] is held in row_offset.


Constructor & Destructor Documentation

PIXROW::PIXROW (  )  [inline]

empty constructor

PIXROW::PIXROW ( inT16  pos,
inT16  count,
PBLOB blob 
)

specified size

PIXROW::~PIXROW (  )  [inline]

destructor


Member Function Documentation

bool PIXROW::bad_box ( int  xsize,
int  ysize 
) const
TBOX PIXROW::bounding_box (  )  const

return bounding box

Returns:
true if box exceeds image
void PIXROW::char_clip_image ( IMAGELINE imlines,
TBOX im_box,
ROW row,
IMAGE clip_image,
float &  baseline_pos 
)
Parameters:
imlines box of imlines extnt
row row containing word
clip_image unscaled char image
baseline_pos baseline ht in image
void PIXROW::contract ( IMAGELINE imlines,
inT16  x_offset,
inT16  foreground_colour 
)

force end on black

Parameters:
imlines image array
x_offset of pixels[0]
foreground_colour 0 or 1
BOOL8 PIXROW::extend ( IMAGELINE imlines,
TBOX imbox,
PIXROW prev,
PIXROW next,
inT16  foreground_colour 
)
Parameters:
imlines image array
prev for prev blob
next for next blob
foreground_colour 0 or 1
void PIXROW::plot ( ScrollView fd  )  const

use current settings

Parameters:
fd where to paint

Member Data Documentation

array of max x

array of min x

length of arrays

y coord of min[0]


The documentation for this class was generated from the following files:
Generated on Sun Jul 18 17:11:12 2010 for Tesseract by  doxygen 1.6.3