[Ffmpeg-cvslog] r6373 - trunk/libavformat/mov.c

bcoudurier subversion
Thu Sep 28 19:59:27 CEST 2006


Author: bcoudurier
Date: Thu Sep 28 19:59:26 2006
New Revision: 6373

Modified:
   trunk/libavformat/mov.c

Log:
move sample size adjusting code after audio stsd v2 parsing to let v2 set correct channel number, fix Sony-hdv2.mov

Modified: trunk/libavformat/mov.c
==============================================================================
--- trunk/libavformat/mov.c	(original)
+++ trunk/libavformat/mov.c	Thu Sep 28 19:59:26 2006
@@ -985,12 +985,6 @@
                 break;
             }
 
-            bits_per_sample = av_get_bits_per_sample(st->codec->codec_id);
-            if (bits_per_sample) {
-                st->codec->bits_per_sample = bits_per_sample;
-                sc->sample_size = (bits_per_sample >> 3) * st->codec->channels;
-            }
-
             //Read QT version 1 fields. In version 0 theese dont exist
             dprintf("version =%d mp4=%d\n",version,c->mp4);
             if(version==1) {
@@ -1008,6 +1002,12 @@
                 get_be32(pb); /* bytes per audio packet if constant */
                 get_be32(pb); /* lpcm frames per audio packet if constant */
             }
+
+            bits_per_sample = av_get_bits_per_sample(st->codec->codec_id);
+            if (bits_per_sample) {
+                st->codec->bits_per_sample = bits_per_sample;
+                sc->sample_size = (bits_per_sample >> 3) * st->codec->channels;
+            }
         } else {
             /* other codec type, just skip (rtp, mp4s, tmcd ...) */
             url_fskip(pb, size - (url_ftell(pb) - start_pos));




More information about the ffmpeg-cvslog mailing list