mirror of
https://github.com/citra-emu/citra.git
synced 2024-12-19 11:21:05 +00:00
gl_rasterizer_cache: validate surface in mipmap/cubemap if the children is not validated yet
This commit is contained in:
parent
88a011ec8e
commit
e3b6bf93bc
@ -1412,6 +1412,9 @@ Surface RasterizerCacheOpenGL::GetTextureSurface(const Pica::Texture::TextureInf
|
||||
|
||||
if (watcher && !watcher->IsValid()) {
|
||||
auto level_surface = watcher->Get();
|
||||
if (!level_surface->invalid_regions.empty()) {
|
||||
ValidateSurface(level_surface, level_surface->addr, level_surface->size);
|
||||
}
|
||||
state.ResetTexture(level_surface->texture.handle);
|
||||
state.Apply();
|
||||
glFramebufferTexture2D(GL_READ_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D,
|
||||
@ -1504,6 +1507,9 @@ const CachedTextureCube& RasterizerCacheOpenGL::GetTextureCube(const TextureCube
|
||||
for (const Face& face : faces) {
|
||||
if (face.watcher && !face.watcher->IsValid()) {
|
||||
auto surface = face.watcher->Get();
|
||||
if (!surface->invalid_regions.empty()) {
|
||||
ValidateSurface(surface, surface->addr, surface->size);
|
||||
}
|
||||
state.ResetTexture(surface->texture.handle);
|
||||
state.Apply();
|
||||
glFramebufferTexture2D(GL_READ_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D,
|
||||
|
Loading…
Reference in New Issue
Block a user