Question

I'm trying to do something similar to this post. But when I try it it throws a fatal exception.

    03-06 16:48:23.421: W/dalvikvm(2300): VFY: unable to resolve exception class 748 (Lcom/google/zxing/ChecksumException;)
    03-06 16:48:23.421: W/dalvikvm(2300): VFY: unable to find exception handler at addr 0xc
    03-06 16:48:23.421: W/dalvikvm(2300): VFY:  rejected Lcom/example/pfc/MainActivity;.onCameraFrame (Lorg/opencv/android/CameraBridgeViewBase$CvCameraViewFrame;)Lorg/opencv/core/Mat;
    03-06 16:48:23.421: W/dalvikvm(2300): VFY:  rejecting opcode 0x0d at 0x000c
    03-06 16:48:23.421: W/dalvikvm(2300): VFY:  rejected Lcom/example/pfc/MainActivity;.onCameraFrame (Lorg/opencv/android/CameraBridgeViewBase$CvCameraViewFrame;)Lorg/opencv/core/Mat;
    03-06 16:48:23.421: W/dalvikvm(2300): Verifier rejected class Lcom/example/pfc/MainActivity;
    03-06 16:48:23.421: W/dalvikvm(2300): Class init failed in newInstance call (Lcom/example/pfc/MainActivity;)
    03-06 16:48:23.421: W/dalvikvm(2300): threadid=1: thread exiting with uncaught exception (group=0x416efd40)
    03-06 16:48:23.424: E/AndroidRuntime(2300): FATAL EXCEPTION: main
    03-06 16:48:23.424: E/AndroidRuntime(2300): Process: com.example.pfc, PID: 2300
    03-06 16:48:23.424: E/AndroidRuntime(2300): java.lang.VerifyError: com/example/pfc/MainActivity
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at java.lang.Class.newInstanceImpl(Native Method)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at java.lang.Class.newInstance(Class.java:1208)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.app.Instrumentation.newActivity(Instrumentation.java:1084)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2126)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2269)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.app.ActivityThread.access$800(ActivityThread.java:139)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1210)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.os.Handler.dispatchMessage(Handler.java:102)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.os.Looper.loop(Looper.java:136)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at android.app.ActivityThread.main(ActivityThread.java:5102)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at java.lang.reflect.Method.invokeNative(Native Method)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at java.lang.reflect.Method.invoke(Method.java:515)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
    03-06 16:48:23.424: E/AndroidRuntime(2300):     at dalvik.system.NativeStart.main(Native Method)

I though it was becase of minimun SDK version but no... Also I know the problem is in the onCameraFrame, because when I comment the try/catch, I can run the app. Any ideas? Thanks.

Was it helpful?

Solution

Solved, the core.jar must be in the Libs folder...

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top