1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
| 1、从github下克隆Tesseract-OCR_for_Windows,注意是克隆不是下载 git clone https:
2、 从github下克隆leptonica git clone https:
3、 从github下克隆tesseract git clone https:
4、把步骤2克隆完成的leptonica文件夹里面文件拷到Tesseract-OCR_for_Windows\leptonica
5、把步骤3克隆完成的tesseract文件夹里面文件拷到Tesseract-OCR_for_Windows\tesseract_3.05 6、tesseract.sln,编译,会有报错。
7、把 static const STRING kCharsToEx[] = {"'", "`", "\"", "\\", ",", ".", "〈", "〉", "《", "》", "」", "「", ""};
修改成 static const STRING kCharsToEx[] = { "'", "`", "\"", "\\", ",", ".", "<", ">", "<<", ">>", "" };
8、再次编译运行,成功。 如果需要dll,打开项目属性,在常规->配置类型处选择动态库;C/C++预处理 -> 预处理器定义处增加TESS_EXPORTS
|