Added a helper function SDL_LockTextureToSurface()

Similar to SDL_LockTexture(), except the locked area is exposed as a SDL surface.
This commit is contained in:
Sylvain Becker 2019-09-30 20:58:44 +02:00
parent f46ac1e9f7
commit 1ae61f1009
6 changed files with 77 additions and 0 deletions

View file

@ -60,6 +60,7 @@ struct SDL_Texture
void *pixels;
int pitch;
SDL_Rect locked_rect;
SDL_Surface *locked_surface; /**< Locked region exposed as a SDL surface */
Uint32 last_command_generation; /* last command queue generation this texture was in. */