Commit 0069fb02 authored by michael's avatar michael

Fix round to even for aspect ratio correction.


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@15173 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 6c5da182
......@@ -731,10 +731,10 @@ static void video_image_display(VideoState *is)
/* XXX: we suppose the screen has a 1.0 pixel ratio */
height = is->height;
width = ((int)rint(height * aspect_ratio)) & -3;
width = ((int)rint(height * aspect_ratio)) & ~1;
if (width > is->width) {
width = is->width;
height = ((int)rint(width / aspect_ratio)) & -3;
height = ((int)rint(width / aspect_ratio)) & ~1;
}
x = (is->width - width) / 2;
y = (is->height - height) / 2;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment