- results[nresults].s= s;
- results[nresults].l= l;
- results[nresults].r= r;
- results[nresults].ctx= ctx;
- nresults++;
+ rd->results[rd->nresults].s= s;
+ rd->results[rd->nresults].l= l;
+ rd->results[rd->nresults].r= r;
+ rd->results[rd->nresults].ctxmap= ctxmap;
+ rd->nresults++;
+}
+
+struct OcrCellTypeInfo {
+ unsigned initial, nextword, midword;
+};
+const struct OcrCellTypeInfo ocr_celltype_number= {
+ 4,4,4
+};
+const struct OcrCellTypeInfo ocr_celltype_text= {
+ .initial=2 /* Uppercase */,
+ .nextword=3 /* Either */,
+ .midword=1 /* Lower only */
+};
+
+static void vdebugf(const char *fmt, va_list al) {
+#ifdef DEBUG_OCR
+ vfprintf(debug,fmt,al);
+#endif
+}
+static void debugf(const char *fmt, ...) {
+ va_list al; va_start(al,fmt); vdebugf(fmt,al); va_end(al);