mirror of
https://github.com/Ryujinx/SDL.git
synced 2025-01-11 15:15:30 +00:00
Add invalidate texture when it changes
This commit is contained in:
parent
5bb965be3d
commit
f75c35c071
|
@ -166,10 +166,11 @@ static int
|
||||||
PS2_UpdateTexture(SDL_Renderer * renderer, SDL_Texture * texture,
|
PS2_UpdateTexture(SDL_Renderer * renderer, SDL_Texture * texture,
|
||||||
const SDL_Rect * rect, const void *pixels, int pitch)
|
const SDL_Rect * rect, const void *pixels, int pitch)
|
||||||
{
|
{
|
||||||
/* PSP_TextureData *psp_texture = (PSP_TextureData *) texture->driverdata; */
|
|
||||||
const Uint8 *src;
|
const Uint8 *src;
|
||||||
Uint8 *dst;
|
Uint8 *dst;
|
||||||
int row, length,dpitch;
|
int row, length,dpitch;
|
||||||
|
GSTEXTURE *ps2_texture = (GSTEXTURE *) texture->driverdata;
|
||||||
|
PS2_RenderData *data = (PS2_RenderData *) renderer->driverdata;
|
||||||
src = pixels;
|
src = pixels;
|
||||||
|
|
||||||
PS2_LockTexture(renderer, texture, rect, (void **)&dst, &dpitch);
|
PS2_LockTexture(renderer, texture, rect, (void **)&dst, &dpitch);
|
||||||
|
@ -184,6 +185,8 @@ PS2_UpdateTexture(SDL_Renderer * renderer, SDL_Texture * texture,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
gsKit_TexManager_invalidate(data->gsGlobal, ps2_texture);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue