[Ffmpeg-cvslog] CVS: ffmpeg/libavformat utils.c,1.166,1.167

Michael Niedermayer CVS michael
Sun Sep 18 16:45:20 CEST 2005


Update of /cvsroot/ffmpeg/ffmpeg/libavformat
In directory mail:/var2/tmp/cvs-serv32144/libavformat

Modified Files:
	utils.c 
Log Message:
print more time_base fps stuff if av_log level is at debug or above
print more likely correct fps
not sure if this is formated optimally ...


Index: utils.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavformat/utils.c,v
retrieving revision 1.166
retrieving revision 1.167
diff -u -d -r1.166 -r1.167
--- utils.c	6 Sep 2005 21:25:35 -0000	1.166
+++ utils.c	18 Sep 2005 14:45:17 -0000	1.167
@@ -2598,6 +2598,7 @@
     }
     for(i=0;i<ic->nb_streams;i++) {
         AVStream *st = ic->streams[i];
+        int g= ff_gcd(st->time_base.num, st->time_base.den);
         avcodec_string(buf, sizeof(buf), st->codec, is_output);
         av_log(NULL, AV_LOG_INFO, "  Stream #%d.%d", index, i);
         /* the pid is an important information, so we display it */
@@ -2612,6 +2613,10 @@
         if (strlen(st->language) > 0) {
             av_log(NULL, AV_LOG_INFO, "(%s)", st->language);
         }
+        av_log(NULL, AV_LOG_DEBUG, ", %d/%d", st->time_base.num/g, st->time_base.den/g);
+        if(st->codec->codec_type == CODEC_TYPE_VIDEO){
+            av_log(NULL, AV_LOG_INFO, ", %5.2f fps", av_q2d(st->r_frame_rate));
+        }
         av_log(NULL, AV_LOG_INFO, ": %s\n", buf);
     }
 }





More information about the ffmpeg-cvslog mailing list