ho_segment.h

Langue: en

Version: 164638 (fedora - 05/07/09)

Section: 3 (Bibliothèques de fonctions)

NAME

src/ho_segment.h - libhocr C language header.

SYNOPSIS


#include <ho_bitmap.h>
#include <ho_objmap.h>

Defines


#define HO_SEGMENT_H 1

Functions


ho_bitmap * ho_segment_paragraphs_fine (const ho_bitmap *m, const unsigned char box, const double font_height_factor_min, const double font_height_factor_max, const double font_width_factor_min, const double font_width_factor_max, const double horizontal_link_factor, const double vertical_link_factor)

ho_bitmap * ho_segment_paragraphs (const ho_bitmap *m, const unsigned char box)

ho_bitmap * ho_segment_lines_fine (const ho_bitmap *m, const double font_height_factor_min, const double font_height_factor_max, const double font_width_factor_min, const double font_width_factor_max, const double link_arg, const double link_arg_2, const double extend_arg, const double extend_arg_2, const double erode_arg)

ho_bitmap * ho_segment_lines (const ho_bitmap *m)

ho_bitmap * ho_segment_words_fine (const ho_bitmap *m, const ho_bitmap *m_line_map, const double horizontal_link_factor, const double top_frame_factor, const double bottom_frame_factor)

ho_bitmap * ho_segment_words (const ho_bitmap *m, const ho_bitmap *m_line_map, const char font_spacing_code)

ho_bitmap * ho_segment_fonts (const ho_bitmap *m, const ho_bitmap *m_line_map, const unsigned char slicing_threshold, const unsigned char slicing_width, const unsigned char line_leeway)

Detailed Description

libhocr C language header.

libhocr - LIBrary for Hebrew Optical Character Recognition

Define Documentation

#define HO_SEGMENT_H 1

Function Documentation

return a bitmap of the paragraphs, font and line dimentions _must_ be set

Parameters:

m pointer to an ho_bitmap
box squre (boxes) or free formed text blocks
font_height_factor_min filter objects height min
font_height_factor_max filter objects height max
font_width_factor_min filter objects width min
font_width_factor_max filter objects width max
horizontal_link_factor link horizontaly factor
vertical_link_factor link verticaly factor

Returns:

a newly allocated bitmap

ho_bitmap* ho_segment_paragraphs (const ho_bitmap * m, const unsigned char box)

return a bitmap of the paragraphs, font and line dimentions _must_ be set

Parameters:

m pointer to an ho_bitmap
box squre (boxes) or free formed text blocks

Returns:

a newly allocated bitmap

return a bitmap of the lines

Parameters:

m pointer to an ho_bitmap
font_height_factor_min filter objects height min
font_height_factor_max filter objects height max
font_width_factor_min filter objects width min
font_width_factor_max filter objects width max
link_arg factor for linking letters in line
link_arg_2 factor for linking letters in line
extend_arg factor for extemding lines horizontaly
extend_arg_2 factor for extemding lines horizontaly
erode_arg factor for eroding line sourface

Returns:

a newly allocated bitmap

ho_bitmap* ho_segment_lines (const ho_bitmap * m)

return a bitmap of the lines

Parameters:

m pointer to an ho_bitmap

Returns:

a newly allocated bitmap

return a bitmap of the words

Parameters:

m pointer to an ho_bitmap of line
m_line_map pointer to an ho_bitmap of line box
horizontal_link_factor horizontal link factor
top_frame_factor top frame factor
bottom_frame_factor bottom frame factor

Returns:

a newly allocated bitmap

ho_bitmap* ho_segment_words (const ho_bitmap * m, const ho_bitmap * m_line_map, const char font_spacing_code)

return a bitmap of the words

Parameters:

m pointer to an ho_bitmap of text
m_line_map pointer to an ho_bitmap of line
font_spacing_code -1:tight 0:normal 1:spaced fonts

Returns:

a newly allocated bitmap

ho_bitmap* ho_segment_fonts (const ho_bitmap * m, const ho_bitmap * m_line_map, const unsigned char slicing_threshold, const unsigned char slicing_width, const unsigned char line_leeway)

return a bitmap of the interfont spaces

Parameters:

m pointer to an ho_bitmap of text
m_line_map pointer to an ho_bitmap of line
slicing_threshold percent of line fill declared space between fonts
slicing_width percent of font width above try to choop font in two
line_leeway percent of line height to use above and below line

Returns:

a newly allocated bitmap

Author

Generated automatically by Doxygen for libhocr from the source code.