diff options
author | sfan5 <sfan5@live.de> | 2021-11-19 23:59:57 +0100 |
---|---|---|
committer | sfan5 <sfan5@live.de> | 2021-11-22 18:08:56 +0100 |
commit | f32ea013dd41a1baa59c1cd696ed29ce21baca99 (patch) | |
tree | 2261220713002744e1d927dd3fbf4549b76b6301 | |
parent | 4ca6c2ff342cf40c8ff7fc5271df357465098942 (diff) | |
download | mpv-f32ea013dd41a1baa59c1cd696ed29ce21baca99.tar.bz2 mpv-f32ea013dd41a1baa59c1cd696ed29ce21baca99.tar.xz |
video: opengl: teach start_frame() about out_fbo == NULL
This case was added in 662c793a557925319493297de8c941a636f18d73
for use in vo_gpu_next as a visibility test before rendering a frame.
The OpenGL context doesn't have this so it just returns true.
-rw-r--r-- | video/out/opengl/context.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/video/out/opengl/context.c b/video/out/opengl/context.c index 59a7eda31c..00cf4b929f 100644 --- a/video/out/opengl/context.c +++ b/video/out/opengl/context.c @@ -214,6 +214,8 @@ int ra_gl_ctx_color_depth(struct ra_swapchain *sw) bool ra_gl_ctx_start_frame(struct ra_swapchain *sw, struct ra_fbo *out_fbo) { struct priv *p = sw->priv; + if (!out_fbo) + return true; *out_fbo = (struct ra_fbo) { .tex = p->wrapped_fb, .flip = !p->params.flipped, // OpenGL FBs are normally flipped |