fixed crash when resizing window to 0
This commit is contained in:
@@ -1573,7 +1573,7 @@ void GraphicsDevice_DX11::CreateBackBufferResources()
|
||||
|
||||
void GraphicsDevice_DX11::SetResolution(int width, int height)
|
||||
{
|
||||
if (width != SCREENWIDTH || height != SCREENHEIGHT)
|
||||
if ((width != SCREENWIDTH || height != SCREENHEIGHT) && width > 0 && height > 0)
|
||||
{
|
||||
SCREENWIDTH = width;
|
||||
SCREENHEIGHT = height;
|
||||
|
||||
@@ -2034,7 +2034,7 @@ namespace wiGraphicsTypes
|
||||
|
||||
void GraphicsDevice_DX12::SetResolution(int width, int height)
|
||||
{
|
||||
if (width != SCREENWIDTH || height != SCREENHEIGHT)
|
||||
if ((width != SCREENWIDTH || height != SCREENHEIGHT) && width > 0 && height > 0)
|
||||
{
|
||||
SCREENWIDTH = width;
|
||||
SCREENHEIGHT = height;
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace wiVersion
|
||||
// minor features, major updates
|
||||
const int minor = 20;
|
||||
// minor bug fixes, alterations, refactors, updates
|
||||
const int revision = 5;
|
||||
const int revision = 6;
|
||||
|
||||
|
||||
long GetVersion()
|
||||
|
||||
Reference in New Issue
Block a user