summaryrefslogtreecommitdiffstats
path: root/libvo
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-02-18 16:49:12 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-02-18 16:49:12 +0000
commit73c3ff74e06a9eb0935a00768f97e34dccab6c61 (patch)
tree31100a24e70be13d87c45389ceb03c83e27cb9e3 /libvo
parent549c10074b85c251c222c64baa2997e7fe6dfc3f (diff)
downloadmpv-73c3ff74e06a9eb0935a00768f97e34dccab6c61.tar.bz2
mpv-73c3ff74e06a9eb0935a00768f97e34dccab6c61.tar.xz
Use the same code to convert fps in float to fraction as used in mencoder,
it ensures all the common frame rates work right. If this causes issues, it should be changed in the same way in mencoder.c git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28650 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r--libvo/vo_yuv4mpeg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libvo/vo_yuv4mpeg.c b/libvo/vo_yuv4mpeg.c
index b983a6ac13..3b7c06c782 100644
--- a/libvo/vo_yuv4mpeg.c
+++ b/libvo/vo_yuv4mpeg.c
@@ -102,7 +102,7 @@ static int config(uint32_t width, uint32_t height, uint32_t d_width,
{
AVRational pixelaspect = av_div_q((AVRational){d_width, d_height},
(AVRational){width, height});
- AVRational fps_frac = av_d2q(vo_fps, INT_MAX);
+ AVRational fps_frac = av_d2q(vo_fps, vo_fps * 1001 + 2);
if (image_width == width && image_height == height &&
image_fps == vo_fps && vo_config_count)
return 0;