Unable to load library 'libtesseract302': The specified module could not
be found
All - I am trying to use tess4j in my Java project. I have followed the
following steps -
copied the jar files from /dist and /lib as a external jar files while
creating the project.
Copied the /tessdata and libtesseract302.dll to the project root and even
in src folder of the project.
Below is the code(tess4j example code in sf) -
import java.io.File;
import net.sourceforge.tess4j.*;
public class ReadingImage {
    public static void main(String[] args) {
        File imageFile = new File("C:\\Documents and Settings\\T9SAUR\\My
Documents\\Downloads\\Tess4J-1.1-src\\Tess4J\\eurotext.tif");
        Tesseract instance = Tesseract.getInstance();
        try {
            String result = instance.doOCR(imageFile);
            System.out.println(result);
        } catch (TesseractException e) {
            System.err.println(e.getMessage());
        }
    }
}
yet my code is giving the error. As per the other post on the same topic,
I checked the JVM version (32 bit) and eclipse version(32 bit). Please let
me know, where I went wrong.
 
No comments:
Post a Comment