From 8a8ed735f6631b2da7bf605c5c3dda4e0fc13905 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Wed, 11 Dec 2013 20:46:04 +0100 Subject: Bug 918 (2/2): Determine StreamWorker usage after stream-init ; Fix seek(..) ; Fallback for EOS Detection ; MovieSimple uses full GLEventListener for 'Audio Only' as well to test seek Determine StreamWorker usage after init - To support audio only files, we need to determine to use StreamWorker after completion of stream-init. Fix seek(..) - FFMPeg: pos0 needs to use aPTS for audio-only - Clip target time [0..duration[ Fallback for EOS Detection In case the backend does not report proper EOS: - Utilize 'nullFramesCount >= MAX' -> EOS, where MAX is number of frames for 3s play duraction and where 'nullFramesCount' is increased if no valid packet is available and no decoded-video or -audio in the queue. - Utilize pts > duration -> EOS MovieSimple uses full GLEventListener for 'Audio Only' as well to test seek - Matroska seek for audio-only leads to EOS .. http://video.webmfiles.org/big-buck-bunny_trailer.webm - MP4 audio-only seek works http://download.blender.org/peach/bigbuckbunny_movies/BigBuckBunny_320x180.mp4 MovieSimple/MovieCube: - Use audio-pts in audio-only to calc target time Tested: - A, V and A+V - Pause, Stop and Seek - GNU/Linux --- src/jogl/classes/com/jogamp/opengl/util/av/GLMediaPlayer.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/jogl/classes/com') diff --git a/src/jogl/classes/com/jogamp/opengl/util/av/GLMediaPlayer.java b/src/jogl/classes/com/jogamp/opengl/util/av/GLMediaPlayer.java index b0a645cbb..22a5cfb32 100644 --- a/src/jogl/classes/com/jogamp/opengl/util/av/GLMediaPlayer.java +++ b/src/jogl/classes/com/jogamp/opengl/util/av/GLMediaPlayer.java @@ -358,7 +358,10 @@ public interface GLMediaPlayer extends TextureSequence { public void initStream(URI streamLoc, int vid, int aid, int textureCount) throws IllegalStateException, IllegalArgumentException; /** - * Returns the {@link StreamException} caught in the decoder thread, or null. + * Returns the {@link StreamException} caught in the decoder thread, or null if none occured. + *

+ * Method clears the cached {@link StreamException}, hence an immediate subsequent call will return null. + *

* @see GLMediaEventListener#EVENT_CHANGE_ERR * @see StreamException */ -- cgit v1.2.3