SDL 2.0.5 requires a full cleanup of the renderer.
This commit is contained in:
parent
f42ca6600a
commit
4b0a029513
1 changed files with 2 additions and 7 deletions
|
|
@ -927,15 +927,10 @@ static void SDL_UpdateRect(SDL_Surface * screen, Sint32 x, Sint32 y, Sint32 w, S
|
||||||
|
|
||||||
SDL_UpdateTexture(texture, &r, screen->pixels + (y * screen->pitch + x * 4), screen->pitch);
|
SDL_UpdateTexture(texture, &r, screen->pixels + (y * screen->pitch + x * 4), screen->pitch);
|
||||||
|
|
||||||
#if !defined (__ANDROID__)
|
// Docs says one must clear the renderer, even if this means a refresh of the whole thing.
|
||||||
// NOTE docs says one should clear the renderer, however this means a refresh of the whole thing.
|
|
||||||
// SDL_RenderClear(renderer);
|
|
||||||
// SDL_RenderCopy(renderer, texture, NULL, NULL);
|
|
||||||
SDL_RenderCopy(renderer, texture, &r, &r);
|
|
||||||
#else
|
|
||||||
SDL_RenderClear(renderer);
|
SDL_RenderClear(renderer);
|
||||||
SDL_RenderCopy(renderer, texture, NULL, NULL);
|
SDL_RenderCopy(renderer, texture, NULL, NULL);
|
||||||
#endif
|
|
||||||
SDL_RenderPresent(renderer);
|
SDL_RenderPresent(renderer);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue