[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gstreamer-cvs
Subject:    gst-plugins-good: qtdemux: stop parsing headers for fragmented mp4s at the first moof
From:       tpm () kemper ! freedesktop ! org (Tim Müller)
Date:       2014-11-30 15:30:53
Message-ID: 20141130153053.E29F676327 () kemper ! freedesktop ! org
[Download RAW message or body]

Module: gst-plugins-good
Branch: master
Commit: 8a0f4e74e445e4dcb37bcff93358b0d0f3daf0aa
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-good/commit/?id=8a0f4e74e445e4dcb37bcff93358b0d0f3daf0aa


Author: Tim-Philipp Müller <tim@centricular.com>
Date:   Fri Aug 15 14:58:26 2014 +0200

qtdemux: stop parsing headers for fragmented mp4s at the first moof

Currently during header parsing, we scan through the entire file
and skip every moof+mdat chunk for fragmented mp4s, which makes
start-up incredibly slow. Instead, just stop at the first moof
chunk when have a moov, and start exposing the streams, so we
can go and start handling the moofs for real.

---

 gst/isomp4/qtdemux.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/gst/isomp4/qtdemux.c b/gst/isomp4/qtdemux.c
index b7b4a07..1db4a31 100644
--- a/gst/isomp4/qtdemux.c
+++ b/gst/isomp4/qtdemux.c
@@ -3106,7 +3106,12 @@ gst_qtdemux_loop_state_header (GstQTDemux * qtdemux)
       if (!qtdemux->moof_offset) {
         qtdemux->moof_offset = qtdemux->offset;
       }
-      /* fall-through */
+      if (qtdemux->got_moov) {
+        GST_INFO_OBJECT (qtdemux, "moof header, got moov, done with headers");
+        ret = GST_FLOW_EOS;
+        goto beach;
+      }
+      break;
     case FOURCC_mdat:
     case FOURCC_free:
     case FOURCC_wide:


[Attachment #3 (text/plain)]

_______________________________________________
gstreamer-commits mailing list
gstreamer-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/gstreamer-commits


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic