typefind: detect 'ftypqt ' as video/quicktime
authorDavid Schleef <ds@schleef.org>
Tue, 29 Sep 2009 03:25:35 +0000 (20:25 -0700)
committerDavid Schleef <ds@schleef.org>
Tue, 6 Oct 2009 19:19:12 +0000 (12:19 -0700)
gst/typefind/gsttypefindfunctions.c

index 418a51a..77edb7e 100644 (file)
@@ -2218,9 +2218,13 @@ qt_type_find (GstTypeFind * tf, gpointer unused)
   guint64 offset = 0;
   guint64 size;
 
-  while ((data = gst_type_find_peek (tf, offset, 8)) != NULL) {
+  while ((data = gst_type_find_peek (tf, offset, 12)) != NULL) {
     guint64 new_offset;
 
+    if (STRNCMP (&data[4], "ftypqt  ", 8) == 0) {
+      tip = GST_TYPE_FIND_MAXIMUM;
+      break;
+    }
     /* box/atom types that are in common with ISO base media file format */
     if (STRNCMP (&data[4], "moov", 4) == 0 ||
         STRNCMP (&data[4], "mdat", 4) == 0 ||