changeset 1271:8c80d41a11cc libavformat

dont set width/height for h261/h263/mpeg4 since they are oftenly wrong, let decoder init them
author bcoudurier
date Thu, 24 Aug 2006 09:09:20 +0000
parents 64be40fc28a5
children 943d9957b96a
files mov.c
diffstat 1 files changed, 13 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mov.c	Thu Aug 24 08:37:51 2006 +0000
+++ b/mov.c	Thu Aug 24 09:09:20 2006 +0000
@@ -1029,7 +1029,20 @@
         st->codec->sample_rate= sc->time_scale;
     }
 
+    /* special codec parameters handling */
     switch (st->codec->codec_id) {
+#ifdef CONFIG_H261_DECODER
+    case CODEC_ID_H261:
+#endif
+#ifdef CONFIG_H263_DECODER
+    case CODEC_ID_H263:
+#endif
+#ifdef CONFIG_MPEG4_DECODER
+    case CODEC_ID_MPEG4:
+#endif
+        st->codec->width= 0; /* let decoder init width/height */
+        st->codec->height= 0;
+        break;
 #ifdef CONFIG_FAAD
     case CODEC_ID_AAC:
 #endif