From 650f28699c79cb817e0d2473cee8b20222877bf0 Mon Sep 17 00:00:00 2001 From: Vincent Povirk Date: Mon, 24 Aug 2009 14:03:28 -0500 Subject: [PATCH] windowscodecs: fix rounding in BMP encoder --- dlls/windowscodecs/bmpencode.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/windowscodecs/bmpencode.c b/dlls/windowscodecs/bmpencode.c index a545103..11c39e8 100644 --- a/dlls/windowscodecs/bmpencode.c +++ b/dlls/windowscodecs/bmpencode.c @@ -333,8 +333,8 @@ static HRESULT WINAPI BmpFrameEncode_Commit(IWICBitmapFrameEncode *iface) bih.bV5BitCount = This->format->bpp; bih.bV5Compression = This->format->compression; bih.bV5SizeImage = This->stride*This->height; - bih.bV5XPelsPerMeter = (This->xres-0.0127) / 0.0254; - bih.bV5YPelsPerMeter = (This->yres-0.0127) / 0.0254; + bih.bV5XPelsPerMeter = (This->xres+0.0127) / 0.0254; + bih.bV5YPelsPerMeter = (This->yres+0.0127) / 0.0254; bih.bV5ClrUsed = 0; bih.bV5ClrImportant = 0; -- 1.5.4.3