diff mencoder.c @ 7058:2e5c07262861

new v4l capture patch by Jindrich Makovicka <makovick@kmlinux.fjfi.cvut.cz>: - multithreaded audio/video buffering (I know mplayer crew hates threads but it seems to me as the only way of doing reliable a/v capture) - a/v timebase synchronization (sample count vs. gettimeofday) - "immediate" mode support for mplayer - fixed colorspace stuff - RGB?? and YUY2 modes now work as expected - native ALSA audio capture - separated audio input layer
author arpi
date Wed, 21 Aug 2002 21:31:20 +0000
parents ab1bf337d8b0
children 0dc9cb756b68
line wrap: on
line diff
--- a/mencoder.c	Wed Aug 21 21:24:23 2002 +0000
+++ b/mencoder.c	Wed Aug 21 21:31:20 2002 +0000
@@ -1126,7 +1126,7 @@
 	if(verbose) {
 		mp_msg(MSGT_AVSYNC,MSGL_STATUS,"Pos:%6.1fs %6df (%2d%%) %3dfps Trem:%4dmin %3dmb  A-V:%5.3f [%d:%d] A/Vms %d/%d D/S %d/%d \r",
 	    	mux_v->timer, decoded_frameno, (int)(p*100),
-	    	(t>1) ? (int)(decoded_frameno/t) : 0,
+	    	(t>1) ? (int)(decoded_frameno/t+0.5) : 0,
 	    	(p>0.001) ? (int)((t/p-t)/60) : 0, 
 	    	(p>0.001) ? (int)(ftello(muxer_f)/p/1024/1024) : 0,
 	    	v_pts_corr,
@@ -1138,7 +1138,7 @@
 	} else
 	mp_msg(MSGT_AVSYNC,MSGL_STATUS,"Pos:%6.1fs %6df (%2d%%) %3dfps Trem:%4dmin %3dmb  A-V:%5.3f [%d:%d]\r",
 	    mux_v->timer, decoded_frameno, (int)(p*100),
-	    (t>1) ? (int)(decoded_frameno/t) : 0,
+	    (t>1) ? (int)(decoded_frameno/t+0.5) : 0,
 	    (p>0.001) ? (int)((t/p-t)/60) : 0, 
 	    (p>0.001) ? (int)(ftell(muxer_f)/p/1024/1024) : 0,
 	    v_pts_corr,
@@ -1187,6 +1187,8 @@
 
 } // while(!at_eof)
 
+if (demuxer) free_demuxer(demuxer);
+
 #ifdef HAVE_MP3LAME
 // fixup CBR mp3 audio header:
 if(sh_audio && mux_a->codec==ACODEC_VBRMP3 && !lame_param_vbr){