mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-04 06:00:15 +00:00
(svn r17910) -Fix: 32bpp BMP screenshots were broken when screen width wasn't multiple of 4
This commit is contained in:
parent
6b76afbc5c
commit
3d177abb14
@ -90,7 +90,8 @@ static bool MakeBmpImage(char *name, ScreenshotCallback *callb, void *userdata,
|
||||
if (f == NULL) return false;
|
||||
|
||||
/* each scanline must be aligned on a 32bit boundary */
|
||||
padw = Align(w, 4);
|
||||
padw = w;
|
||||
if (pixelformat == 8) padw = Align(padw, 4);
|
||||
|
||||
if (pixelformat == 8) pal_size = sizeof(RgbQuad) * 256;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user