From 86096e677c97c130c87767a092a6e398c8b7fd2a Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 2 Oct 2017 00:48:31 +0200 Subject: [PATCH] Update --- gfx/common/d3d_common.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gfx/common/d3d_common.cpp b/gfx/common/d3d_common.cpp index 0b7a430aaf..2e457ce2a5 100644 --- a/gfx/common/d3d_common.cpp +++ b/gfx/common/d3d_common.cpp @@ -312,12 +312,14 @@ bool d3d_device_create_offscreen_plain_surface( void **surf_data, void *data) { - if (FAILED(dev->CreateOffscreenPlainSurface(width, height, +#if defined(HAVE_D3D9) + if (SUCCEEDED(dev->CreateOffscreenPlainSurface(width, height, (D3DFORMAT)format, (D3DPOOL)pool, (LPDIRECT3DSURFACE*)surf_data, (HANDLE*)data))) - return false; - return true; + return true; +#endif + return false; } static void d3d_set_texture_stage_state(LPDIRECT3DDEVICE dev,