diff utils.c @ 5653:25eca7e2cf64 libavformat

Add flag so muxers not needing width/height can signal this. Add this flag to img2 (fixes -vcodec copy to image2 in some cases)
author michael
date Fri, 12 Feb 2010 20:35:29 +0000
parents 7309cd6645b6
children 6d530eb42996
line wrap: on
line diff
--- a/utils.c	Fri Feb 12 11:31:35 2010 +0000
+++ b/utils.c	Fri Feb 12 20:35:29 2010 +0000
@@ -2546,7 +2546,7 @@
                 av_log(s, AV_LOG_ERROR, "time base not set\n");
                 return -1;
             }
-            if(st->codec->width<=0 || st->codec->height<=0){
+            if((st->codec->width<=0 || st->codec->height<=0) && !(s->oformat->flags & AVFMT_NODIMENSIONS)){
                 av_log(s, AV_LOG_ERROR, "dimensions not set\n");
                 return -1;
             }