嗨,我正在研究OCR(光学字符识别),我从 github 获得了一个示例项目。对于这个项目,我正在使用 tess-test 库项目,项目构建并成功执行,但是每当调用 TessBaseAPI 时,应用程序就会不幸停止......它显示以下日志错误
12-20 18:27:18.791: E/AndroidRuntime(24466): java.lang.ExceptionInInitializerError
12-20 18:27:18.791: E/AndroidRuntime(24466): at com.datumdroid.android.ocr.simple.SimpleAndroidOCRActivity.onPhotoTaken(SimpleAndroidOCRActivity.java:211)
12-20 18:27:18.791: E/AndroidRuntime(24466): at com.datumdroid.android.ocr.simple.SimpleAndroidOCRActivity.onActivityResult(SimpleAndroidOCRActivity.java:135)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.app.Activity.dispatchActivityResult(Activity.java:5293)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.app.ActivityThread.deliverResults(ActivityThread.java:3315)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.app.ActivityThread.handleSendResult(ActivityThread.java:3362)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.app.ActivityThread.access$1100(ActivityThread.java:141)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1282)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.os.Handler.dispatchMessage(Handler.java:99)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.os.Looper.loop(Looper.java:137)
12-20 18:27:18.791: E/AndroidRuntime(24466): at android.app.ActivityThread.main(ActivityThread.java:5039)
12-20 18:27:18.791: E/AndroidRuntime(24466): at java.lang.reflect.Method.invokeNative(Native Method)
12-20 18:27:18.791: E/AndroidRuntime(24466): at java.lang.reflect.Method.invoke(Method.java:511)
12-20 18:27:18.791: E/AndroidRuntime(24466): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
12-20 18:27:18.791: E/AndroidRuntime(24466): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
12-20 18:27:18.791: E/AndroidRuntime(24466): at dalvik.system.NativeStart.main(Native Method)
12-20 18:27:18.791: E/AndroidRuntime(24466): Caused by: java.lang.UnsatisfiedLinkError: Couldn't load lept from loader dalvik.system.PathClassLoader[dexPath=/data/app/com.datumdroid.android.ocr.simple-1.apk,libraryPath=/data/app-lib/com.datumdroid.android.ocr.simple-1]: findLibrary returned null
12-20 18:27:18.791: E/AndroidRuntime(24466): at java.lang.Runtime.loadLibrary(Runtime.java:365)
12-20 18:27:18.791: E/AndroidRuntime(24466): at java.lang.System.loadLibrary(System.java:535)
12-20 18:27:18.791: E/AndroidRuntime(24466): at com.googlecode.tesseract.android.TessBaseAPI.<clinit>(TessBaseAPI.java:47)
请解决我的问题,因为我的申请需要 5 天。
我google了很多没有找到任何解决方案..谢谢