changeset 4598:badb76094897

setting vo_fps, required for vo_yuv4mpeg
author arpi
date Sat, 09 Feb 2002 01:29:11 +0000
parents 4ba62f7d04c6
children 88843786301e
files mplayer.c
diffstat 1 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mplayer.c	Sat Feb 09 01:25:21 2002 +0000
+++ b/mplayer.c	Sat Feb 09 01:29:11 2002 +0000
@@ -1065,6 +1065,14 @@
 	   sh_video->fps,sh_video->frametime
 	   );
 
+    vo_fps = sh_video->fps;
+    /* need to set fps here for output encoders to pick it up in their init */
+    if(force_fps){
+      sh_video->fps=force_fps;
+      sh_video->frametime=1.0f/sh_video->fps;
+      vo_fps = force_fps;
+    }
+
     if(!sh_video->fps && !force_fps){
       mp_msg(MSGT_CPLAYER,MSGL_ERR,MSGTR_FPSnotspecified);
       sh_video=d_video->sh=NULL;
@@ -1476,7 +1484,7 @@
 
 if(demuxer->file_format!=DEMUXER_TYPE_AVI) pts_from_bps=0; // it must be 0 for mpeg/asf!
 if(force_fps){
-  sh_video->fps=force_fps;
+  vo_fps = sh_video->fps=force_fps;
   sh_video->frametime=1.0f/sh_video->fps;
   mp_msg(MSGT_CPLAYER,MSGL_INFO,MSGTR_FPSforced,sh_video->fps,sh_video->frametime);
 }