ccstruct/blobs.h

Go to the documentation of this file.
00001 
00021 #ifndef BLOBS_H
00022 #define BLOBS_H
00023 
00024 /*----------------------------------------------------------------------
00025               I n c l u d e s
00026 ----------------------------------------------------------------------*/
00027 #include                   "vecfuncs.h"
00028 #include  "tessclas.h"
00029 
00030 /*----------------------------------------------------------------------
00031               T y p e s
00032 ----------------------------------------------------------------------*/
00040 typedef struct
00041 {
00042   int num_chars;
00043   int widths[1];
00044 } WIDTH_RECORD;
00045 
00046 /*----------------------------------------------------------------------
00047               M a c r o s
00048 ----------------------------------------------------------------------*/
00052 #define free_widths(w)  if (w) memfree (w)
00053 
00054 /*----------------------------------------------------------------------
00055               F u n c t i o n s
00056 ----------------------------------------------------------------------*/
00057 void blob_origin(TBLOB *blob,      /*blob to compute on */
00058                  TPOINT *origin);  /*return value */
00059 
00060                                  /*blob to compute on */
00061 void blob_bounding_box(TBLOB *blob,
00062                        register TPOINT *topleft,  /*bounding box */
00063                        register TPOINT *botright);
00064 
00065 void blobs_bounding_box(TBLOB *blobs, TPOINT *topleft, TPOINT *botright); 
00066 
00067 void blobs_origin(TBLOB *blobs,     /*blob to compute on */
00068                   TPOINT *origin);  /*return value */
00069 
00070                                  /*blob to compute on */
00071 WIDTH_RECORD *blobs_widths(TBLOB *blobs); 
00072 
00073 int count_blobs(TBLOB *blobs); 
00074 
00075 void delete_word(TWERD *word); 
00076 
00077 void delete_edgepts(register EDGEPT *edgepts); 
00078 
00079 /*
00080 #if defined(__STDC__) || defined(__cplusplus)
00081 # define _ARGS(s) s
00082 #else
00083 # define _ARGS(s) ()
00084 #endif*/
00085 
00086 /* blobs.c
00087 void blob_origin
00088   _ARGS((BLOB *blob,
00089   TPOINT *origin));
00090 
00091 void blob_bounding_box
00092   _ARGS((BLOB *blob,
00093   TPOINT *topleft,
00094   TPOINT *botright));
00095 
00096 void blobs_bounding_box
00097   _ARGS((BLOB *blobs,
00098   TPOINT *topleft,
00099   TPOINT *botright));
00100 
00101 void blobs_origin
00102   _ARGS((BLOB *blobs,
00103   TPOINT *origin));
00104 
00105 WIDTH_RECORD *blobs_widths
00106   _ARGS((BLOB *blobs));
00107 
00108 int count_blobs
00109   _ARGS((BLOB *blobs));
00110 
00111 void delete_word
00112   _ARGS((TWERD *word));
00113 
00114 void delete_edgepts
00115   _ARGS((EDGEPT *edgepts));
00116 #undef _ARGS
00117 */
00118 #endif

Generated on Wed Feb 28 19:49:08 2007 for Tesseract by  doxygen 1.5.1