我第一次尝试使用tesseract,编译时出现以下错误:
Unhandled exception at 0x76F88F05 (ntdll.dll) in lpr.exe: 0xC0150002: Windows was not able to process the application binding information. Please refer to your System Event Log for further information.
任何人都可以帮助我吗?
以下是代码:
char *outText;
tesseract::TessBaseAPI *api = new tesseract::TessBaseAPI();
// Initialize tesseract-ocr with English, without specifying tessdata path
if (api->Init(NULL, "eng")) {
fprintf(stderr, "Could not initialize tesseract.\n");
exit(1);
}
// Open input image with leptonica library
Pix *image = pixRead("B:\Projects\Visual 2013\lpr\lpr\placuta.jpeg");
api->SetImage(image);
// Get OCR result
outText = api->GetUTF8Text();
printf("OCR output:\n%s", outText);
// Destroy used object and release memory
api->End();
delete[] outText;
pixDestroy(&image);
事件日志消息:
&B; \ Projects \ Visual 2013 \ lpr \ lpr \ libtesseract302d.dll"的激活上下文生成失败。
无法找到依赖大会
Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8"
。请使用sxstrace.exe进行详细诊断。
答案 0 :(得分:0)
感谢Colin Robertson
这对我来说:vorba.ch/2014/tesseract-3.03-vs2013.html -
按照以下步骤操作后,将从tesseract google下载的lib文件包含到您的项目中。