mirror of
https://github.com/mpv-player/mpv
synced 2024-12-27 17:42:17 +00:00
vo_opengl: fix filter reinitialization
The second scaling filter (cscale) was never reset correctly due to a fatal oversight. In particular, this could lead to OpenGL errors, if the new filter needs a 2D texture, but the old texture was 1D (because init_scaler reuses the texture).
This commit is contained in:
parent
44d1756e33
commit
c176499925
@ -948,10 +948,10 @@ static void uninit_rendering(struct gl_priv *p)
|
||||
delete_shaders(p);
|
||||
|
||||
for (int n = 0; n < 2; n++) {
|
||||
gl->DeleteTextures(1, &p->scalers->gl_lut);
|
||||
p->scalers->gl_lut = 0;
|
||||
p->scalers->lut_name = NULL;
|
||||
p->scalers->kernel = NULL;
|
||||
gl->DeleteTextures(1, &p->scalers[n].gl_lut);
|
||||
p->scalers[n].gl_lut = 0;
|
||||
p->scalers[n].lut_name = NULL;
|
||||
p->scalers[n].kernel = NULL;
|
||||
}
|
||||
|
||||
gl->DeleteTextures(1, &p->dither_texture);
|
||||
|
Loading…
Reference in New Issue
Block a user