Main Page | Class List | Directories | File List | Class Members | File Members

gocr_module.h File Reference

This is the module header. More...

#include <stdio.h>
#include "hash.h"
#include "list.h"
#include "unicode.h"
#include "gocr_image.h"
#include "gocr_char.h"
#include "gocr_block.h"
#include "gocr_gui.h"
#include "gocr.h"

Go to the source code of this file.

Classes

struct  gocr_modulefunctioninfo
 Module function information. More...
struct  gocr_moduleattributeinfo
 Module package attributes information. More...
struct  gocr_moduleinfo

Module data.

typedef gocr_modulefunctioninfo gocr_ModuleFunctionInfo
 Typedef encapsulation.
typedef gocr_moduleattributeinfo gocr_ModuleAttributeInfo
 Typedef encapsulation.
typedef gocr_moduleinfo gocr_ModuleInfo
 Typedef encapsulation.

Debugging utilities

*int gocr_printArea (gocr_Image *image, int x0, int y0, int x1, int y1)
 prints an image.
int gocr_printBlock (gocr_Block *b)
 prints a block.
int gocr_printBox (gocr_Box *b)
 prints a box.
int gocr_printBox2 (gocr_Box *b1, gocr_Box *b2)
 prints two boxes.


Detailed Description

This is the module header.

Author:
Bruno Barberi Gnecco <brunobg@sourceforge.net>

Function Documentation

* int gocr_printArea gocr_Image image,
int  x0,
int  y0,
int  x1,
int  y1
 

prints an image.

This function prints an image to the file specified by the ERROR_FILE attribute, formatted according to the PRINT attribute:

  • 0: only data bit (. = WHITE, * = BLACK)
  • 1: marked bits (mark1 + 2*mark2 + 4*mark3)
  • 2: data and marked bits: if white, a...h; if black, A..H
  • 3: only isblock bit (. = is not block, * = is block)
  • 4: only ischar bit (. = is not char, * = is char)
  • 5: complete byte, in hexadecimal
  • 6: complete byte, in ASCII.

Refer to the PostScript documentation for a more detailed description.

Parameters:
new A pointer to the image.
x0,y0 A vertex of the area to be copied.
x1,y1 The opposite vertex.
See also:
gocr_setAttribute, gocr_getAttribute, PS documentation.
Return values:
0 OK
-1 error.

int gocr_printBlock gocr_Block b  ) 
 

prints a block.

This function prints a block to the file specified by the ERROR_FILE attribute. If PRINT_IMAGE attribute is 1 (true), the image of the block will be printed too.

Parameters:
b A pointer to the block.
See also:
gocr_setAttribute, gocr_getAttribute, gocr_printImage.
Return values:
0 OK
-1 error.

int gocr_printBox gocr_Box b  ) 
 

prints a box.

This function prints a box to the file specified by the ERROR_FILE attribute. If PRINT_IMAGE attribute is 1 (true), the image of the box will be printed too.

Parameters:
b A pointer to the box.
See also:
gocr_setAttribute, gocr_getAttribute, gocr_printImage.
Return values:
0 OK
-1 error.

int gocr_printBox2 gocr_Box b1,
gocr_Box b2
 

prints two boxes.

This function prints two boxes side by side, to the file specified by the ERROR_FILE attribute. If PRINT_IMAGE attribute is 1 (true), the image of the boxes will be printed too.

Parameters:
b A pointer to the box.
See also:
gocr_setAttribute, gocr_getAttribute, gocr_printImage.
Return values:
0 OK
-1 error.


Generated on Sun Jul 31 13:19:14 2005 for GOCR API by  doxygen 1.4.3-20050530