Unverified Commit d05a2e45 authored by Bobby Smith's avatar Bobby Smith Committed by GitHub
Browse files

Fixes black boxes issue with GL when video is reinitialized (#1076)

parent e9e17e32
Pipeline #23320 passed with stage
in 10 minutes and 9 seconds
......@@ -383,6 +383,7 @@ void main()
int max_image_width;
int max_image_height;
extern GLuint fogTextureId;
extern GLuint paletteTextureId;
bool gl4CompilePipelineShader( gl4PipelineShader* s, const char *pixel_source /* = PixelPipelineShader */, const char *vertex_source /* = NULL */)
{
......@@ -491,6 +492,8 @@ static void gl_term(void)
fbTextureId = 0;
glDeleteTextures(1, &fogTextureId);
fogTextureId = 0;
glcache.DeleteTextures(1, &paletteTextureId);
paletteTextureId = 0;
}
static bool gl_create_resources(void)
......@@ -921,6 +924,7 @@ struct gl4rend : Renderer
}
#endif
fog_needs_update = true;
palette_updated = true;
TexCache.Clear();
if (settings.rend.PowerVR2Filter)
......
......@@ -685,6 +685,8 @@ static void gl_term(void)
fbTextureId = 0;
glDeleteTextures(1, &fogTextureId);
fogTextureId = 0;
glcache.DeleteTextures(1, &paletteTextureId);
paletteTextureId = 0;
gl_delete_shaders();
}
......@@ -1111,6 +1113,7 @@ struct glesrend : Renderer
}
#endif
fog_needs_update = true;
palette_updated = true;
TexCache.Clear();
if (settings.rend.PowerVR2Filter)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment