mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2025-01-31 00:09:19 +01:00
Fixed Bug 3147 - Windows: Crash when resizing Window since hg 1f9d57965528
Thanks for the fix, Gab!
This commit is contained in:
parent
ce456cfb8e
commit
23af328bb0
@ -1004,6 +1004,10 @@ D3D_RecreateTexture(SDL_Renderer * renderer, SDL_Texture * texture)
|
|||||||
D3D_RenderData *data = (D3D_RenderData *)renderer->driverdata;
|
D3D_RenderData *data = (D3D_RenderData *)renderer->driverdata;
|
||||||
D3D_TextureData *texturedata = (D3D_TextureData *)texture->driverdata;
|
D3D_TextureData *texturedata = (D3D_TextureData *)texture->driverdata;
|
||||||
|
|
||||||
|
if (!texturedata) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
if (D3D_RecreateTextureRep(data->device, &texturedata->texture, texture->format, texture->w, texture->h) < 0) {
|
if (D3D_RecreateTextureRep(data->device, &texturedata->texture, texture->format, texture->w, texture->h) < 0) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user