fix: DD_DoDisplay would not update the display if resolution had just been changed

This commit is contained in:
SuuperW 2018-08-18 11:28:46 -05:00
parent c9b41e3c53
commit c4ea4ad879
1 changed files with 3 additions and 5 deletions

View File

@ -457,14 +457,12 @@ static void OGL_DoDisplay()
}
static void DD_DoDisplay()
{
if (ddraw.surfDescBack.dwWidth != video.rotatedwidth() || ddraw.surfDescBack.dwHeight != video.rotatedheight())
ddraw.createBackSurface(video.rotatedwidth(), video.rotatedheight());
if (!ddraw.lock()) return;
char* buffer = (char*)ddraw.surfDescBack.lpSurface;
if (ddraw.surfDescBack.dwWidth != video.rotatedwidth() || ddraw.surfDescBack.dwHeight != video.rotatedheight())
{
ddraw.createBackSurface(video.rotatedwidth(), video.rotatedheight());
}
switch (ddraw.surfDescBack.ddpfPixelFormat.dwRGBBitCount)
{
case 32: