Fix taking screenshots whose width is not congruent to 0 mod 4.

Closes #3537.
master
safety0ff 2012-06-07 14:45:14 -04:00
parent c94112b6b3
commit 62153e972f
1 changed files with 1 additions and 0 deletions

View File

@ -432,6 +432,7 @@ void screenDoDumpToDiskIfRequired(void)
return;
}
}
glPixelStorei(GL_PACK_ALIGNMENT, 1);
glReadPixels(0, 0, image.width, image.height, GL_RGB, GL_UNSIGNED_BYTE, image.bmp);
iV_saveImage_PNG(fileName, &image);