diff options
Diffstat (limited to 'video/out/opengl')
-rw-r--r-- | video/out/opengl/ra_gl.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/video/out/opengl/ra_gl.c b/video/out/opengl/ra_gl.c index 5b03368436..37b7285235 100644 --- a/video/out/opengl/ra_gl.c +++ b/video/out/opengl/ra_gl.c @@ -996,6 +996,10 @@ static void gl_renderpass_run(struct ra *ra, assert(params->target->params.render_dst); assert(params->target->params.format == pass->params.target_format); gl->BindFramebuffer(GL_FRAMEBUFFER, target_gl->fbo); + if (pass->params.invalidate_target && gl->InvalidateFramebuffer) { + GLenum fb = target_gl->fbo ? GL_COLOR_ATTACHMENT0 : GL_COLOR; + gl->InvalidateFramebuffer(GL_FRAMEBUFFER, 1, &fb); + } gl->Viewport(params->viewport.x0, params->viewport.y0, mp_rect_w(params->viewport), mp_rect_h(params->viewport)); |