gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-


From: Sandro Santilli
Subject: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-1814-g1606ab4
Date: Sun, 03 Nov 2013 18:54:19 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnash".

The branch, master has been updated
       via  1606ab48c70dcdda3ca95ff5212b836418b01c3d (commit)
       via  7a53cb38d4b3f8a8f6160a40e2912133663c1ab3 (commit)
      from  77966b2317f6f4914b5f10c49852ffe6c7881cab (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit//commit/?id=1606ab48c70dcdda3ca95ff5212b836418b01c3d


commit 1606ab48c70dcdda3ca95ff5212b836418b01c3d
Author: Sandro Santilli <address@hidden>
Date:   Sun Nov 3 19:50:53 2013 +0100

    Downgrade partial audio frame decoding from error to debug info
    
    Legit callers can request decoding of chunks of input crossing the
    boundaries of audio frames, expecting decoder to be stateful.
    See https://savannah.gnu.org/bugs/index.php?24638

diff --git a/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp 
b/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp
index 7239daf..653e8a2 100644
--- a/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp
+++ b/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp
@@ -392,35 +392,14 @@ AudioDecoderFfmpeg::decode(const boost::uint8_t* input,
 
         if ( ! framesize )
         {
-            // If nothing is consumed, this will fail. It can happen if a
-            // block is passed to the decoder when nothing can be 
-            // parsed from the block. This is probably a malformed SWF.
-            //assert(decodedBytes == inputSize);
-
-            // NOTE: If this happens the caller sent us
-            //       a block of data which is not composed
-            //       by complete audio frames.
-            //       Could be due to an error in the caller
-            //       code, or to a malformed SWF...
-            //       At time of writing this (2008-11-01)
-            //       it is most likely an error in caller
-            //       code (streaming sound/event sound)
-            //       so we log an ERROR rather then a
-            //       MALFORMED input. You can uncomment the
-            //       abort below to check who is the caller 
-            //       with gdb. When callers are checked,
-            //       we may turn this into a MALFORMED
-            //       kind of error (DEFINESOUND, SOUNDSTREAMBLOCK
-            //       or FLV AudioTag not containing full audio frames)
-            //
-
-            log_error(_("AudioDecoderFfmpeg: "
+            // See https://savannah.gnu.org/bugs/?25456
+            // for a live testcase
+            log_debug("AudioDecoderFfmpeg: "
                       "could not find a complete frame in "
-                      "the last %d bytes of input"
-                        " (malformed SWF or FLV?)"),
-                      consumed);
-            //abort();
-            continue;
+                      "the last %d bytes of a %d bytes block"
+                        " (nothing should be lost)",
+                      consumed, inputSize);
+            break; 
         }
 
 

http://git.savannah.gnu.org/cgit//commit/?id=7a53cb38d4b3f8a8f6160a40e2912133663c1ab3


commit 7a53cb38d4b3f8a8f6160a40e2912133663c1ab3
Author: Sandro Santilli <address@hidden>
Date:   Sun Nov 3 19:49:28 2013 +0100

    Decode embedded sound in chunks of 65535 bytes
    
    Fixes latency in lessig-freeculture.swf:
    https://savannah.gnu.org/bugs/?25456
    
    Confirms AudioDecoder is already allowed to do incremental decoding:
    https://savannah.gnu.org/bugs/index.php?24638

diff --git a/libsound/EmbedSoundInst.cpp b/libsound/EmbedSoundInst.cpp
index 4c7023c..cecfb52 100644
--- a/libsound/EmbedSoundInst.cpp
+++ b/libsound/EmbedSoundInst.cpp
@@ -91,7 +91,15 @@ EmbedSoundInst::decodeNextBlock()
 {
     assert(!decodingCompleted());
 
-    const boost::uint32_t inputSize = _soundDef.size() - decodingPosition;
+    // this value is arbitrary, things would also work
+    // with a smaller value, but 2^16 seems fast enough
+    // to decode not to bother further streamlining it
+    // See https://savannah.gnu.org/bugs/?25456 for a testcase
+    // showing the benefit of chunked decoding.
+    const boost::uint32_t chunkSize = 65535;
+
+    boost::uint32_t inputSize = _soundDef.size() - decodingPosition;
+    if ( inputSize > chunkSize ) inputSize = chunkSize;
 
 #ifdef GNASH_DEBUG_SOUNDS_DECODING
     log_debug("  decoding %d bytes", inputSize);

-----------------------------------------------------------------------

Summary of changes:
 libmedia/ffmpeg/AudioDecoderFfmpeg.cpp |   35 ++++++-------------------------
 libsound/EmbedSoundInst.cpp            |   10 ++++++++-
 2 files changed, 16 insertions(+), 29 deletions(-)


hooks/post-receive
-- 
Gnash



reply via email to

[Prev in Thread] Current Thread [Next in Thread]