6

I'm developing an Android app which uses tesseract OCR to recognize Text, now I have the Problem that on different Smartphones the image gets rotate in a different way, so on one it is in landscape mode right away and on the other in portrait mode. So now i want to intelligently rotate the Image so that Tesseract can recognize the Text. Which is only in one of the two options possible, but it might be in either, due to the user taking the picture. I don't want the User to have to take the picture in the same format everytime, i want to rotate it so it fits the need, if possible without too much of a performance loss.

The Tesseract lib with the autorotate does not seem to work for me in that way. Anybody an idea how to solve that problem.

Thanks

4

2 回答 2

2

如果这个问题仍然与您相关:也许您可以提取图像的 exif 数据,以获取其方向?

否则,本文可能会对您有所帮助:使用 Tesseract OCR 引擎结合定向和脚本检测

于 2014-12-15T13:34:52.127 回答
1

如果您不介意卷起袖子,http://www.leptonica.org/可能是评估字形(尚未检测为文本的原始 Pix)和确定方向的好选择。我已经看到对 Leptonica 的 Android 绑定的引用。

于 2015-01-20T19:40:53.490 回答