Video Not Implemented Yet?
in
Android Processing
•
3 years ago
Let me just say this is great so far! Most the sketches have worked on my Samsung Vibrant with Android 2.1 and they even work with the TV Out feature so I can project them with my pocket projector! Time for some street VJing!
However, I can't get the video library to work. I started with the "Loop" example and changed the video file to one that I know for a fact works in Android. When I run the sketch, I get this error:
Looking at the debug log, it seems that the video library is still trying to use QuickTime; I guess it's not ported yet? I would like to try to implement it, but I'm not even sure there's a way... I've looked all over the Android API at VideoView and MediaPlayer, but there's no way to get the pixels from the frame of a video that I can tell. I'm thinking about trying to render it to a VideoView, then grabbing the pixels from the View somehow? Does anyone know of a potential solution?
Debug log:
However, I can't get the video library to work. I started with the "Loop" example and changed the video file to one that I know for a fact works in Android. When I run the sketch, I get this error:
- java.lang.VerifyError: processing.video.Movie
at processing.android.test.loop.Loop.setup(Loop.java:31)
at processing.core.PApplet.handleDraw(PApplet.java:1739)
at processing.core.PGraphicsAndroid2D.requestDraw(PGraphicsAndroid2D.java:161)
at processing.core.PApplet.run(PApplet.java:1630)
at java.lang.Thread.run(Thread.java:1096)
Looking at the debug log, it seems that the video library is still trying to use QuickTime; I guess it's not ported yet? I would like to try to implement it, but I'm not even sure there's a way... I've looked all over the Android API at VideoView and MediaPlayer, but there's no way to get the pixels from the frame of a video that I can tell. I'm thinking about trying to render it to a VideoView, then grabbing the pixels from the View somehow? Does anyone know of a potential solution?
Debug log:
- I/System.out(21354): done with loop() call, will continue...
- I/processing.android.test.loop(21354): PROCESSING onStart
- I/ActivityManager( 2246): Displayed activity processing.android.test.loop/.Loop:
- 317 ms (total 317 ms)
- D/dalvikvm(21354): GC freed 141 objects / 6392 bytes in 28ms
- W/dalvikvm(21354): VFY: unable to find class referenced in signature (Lquicktime
- /std/movies/media/DataRef;)
- I/dalvikvm(21354): Could not find method quicktime.std.movies.Movie.fromDataRef,
- referenced from method processing.video.Movie.fromDataRef
- W/dalvikvm(21354): VFY: unable to resolve static method 2788: Lquicktime/std/mov
- ies/Movie;.fromDataRef (Lquicktime/std/movies/media/DataRef;I)Lquicktime/std/mov
- ies/Movie;
- D/dalvikvm(21354): VFY: replacing opcode 0x71 at 0x0002
- D/dalvikvm(21354): Making a copy of Lprocessing/video/Movie;.fromDataRef code (3
- 2 bytes)
- I/dalvikvm(21354): Could not find method quicktime.QTSession.close, referenced f
- rom method processing.video.Movie.dispose
- W/dalvikvm(21354): VFY: unable to resolve static method 2756: Lquicktime/QTSessi
- on;.close ()V
- D/dalvikvm(21354): VFY: replacing opcode 0x71 at 0x0006
- D/dalvikvm(21354): Making a copy of Lprocessing/video/Movie;.dispose code (36 by
- tes)
- I/dalvikvm(21354): Could not find method quicktime.std.movies.Movie.getDuration,
- referenced from method processing.video.Movie.duration
- W/dalvikvm(21354): VFY: unable to resolve virtual method 2790: Lquicktime/std/mo
- vies/Movie;.getDuration ()I
- D/dalvikvm(21354): VFY: replacing opcode 0x6e at 0x0002
- D/dalvikvm(21354): Making a copy of Lprocessing/video/Movie;.duration code (81 b
- ytes)
- W/dalvikvm(21354): VFY: unable to resolve exception class 233 (Lquicktime/std/St
- dQTException;)
- W/dalvikvm(21354): VFY: unable to find exception handler at addr 0x10
- W/dalvikvm(21354): VFY: rejected Lprocessing/video/Movie;.duration ()F
- W/dalvikvm(21354): VFY: rejecting opcode 0x0d at 0x0010
- W/dalvikvm(21354): VFY: rejected Lprocessing/video/Movie;.duration ()F
- W/dalvikvm(21354): Verifier rejected class Lprocessing/video/Movie;
- W/dalvikvm(21354): threadid=17: thread exiting with uncaught exception (group=0x
- 4001dc20)
- E/AndroidRuntime(21354): Uncaught handler: thread Animation Thread exiting due t
- o uncaught exception
- E/AndroidRuntime(21354): java.lang.VerifyError: processing.video.Movie
- E/AndroidRuntime(21354): at processing.android.test.loop.Loop.setup(Loop.
- java:31)
- E/AndroidRuntime(21354): at processing.core.PApplet.handleDraw(PApplet.ja
- va:1739)
- E/AndroidRuntime(21354): at processing.core.PGraphicsAndroid2D.requestDra
- w(PGraphicsAndroid2D.java:161)
- E/AndroidRuntime(21354): at processing.core.PApplet.run(PApplet.java:1630
- )
- E/AndroidRuntime(21354): at java.lang.Thread.run(Thread.java:1096)
- I/Process ( 2246): Sending signal. PID: 21354 SIG: 3
- I/dalvikvm(21354): threadid=7: reacting to signal 3
- I/ANDROID_DEBUG( 2246): dumpmesg > /data/log/dumpstate_app_201010102251_processi
- ng_android_test_loop.log
- I/dalvikvm(21354): Wrote stack trace to '/data/anr/traces.txt'
- D/SensorManager(21367): ====>>>>>Num Sensor: 1
- D/SensorManager(21367): found sensor: SMB380, handle=0
- D/SensorManager(21367): ====>>>>>Num Sensor: 2
- D/SensorManager(21367): found sensor: MS-3C Magnetic Sensor, handle=1
- D/SensorManager(21367): ====>>>>>Num Sensor: 3
- D/SensorManager(21367): found sensor: MS-3C Orientation Sensor, handle=2
- D/SensorManager(21367): ====>>>>>Num Sensor: 4
- D/SensorManager(21367): found sensor: gp2a Proximity Sensor, handle=7
- D/SensorManager(21367): ====>>>>>Num Sensor: 0
- D/SensorManager(21367): found sensor: gp2a Light Sensor, handle=4
- E/SensorManager(21367): ####### akmd2 started!!!
- D/LocationManager(21367): Constructor: service = android.location.ILocationManag
- er$Stub$Proxy@47b5cd90
- I/dumpstate(21380): begin
- I/dumpstate(21380): done
- I/ActivityManager( 2246): Process com.svox.pico (pid 21357) has died.
- I/ActivityManager( 2246): Process com.android.voicedialer (pid 21335) has died.
- I/ActivityManager( 2246): Process com.android.mms (pid 21298) has died.
- I/AlarmManager( 2246): mWakeLock.acquire(500);
- W/AlarmBroadcastReceiver(20655): Unknown package: alarms not restarted.
- D/SlackerRadio(18910): appwidget.SlackerAppWidgetProvider.### onReceive: context
1