summaryrefslogtreecommitdiffstats
path: root/video/out/gl_video.c
diff options
context:
space:
mode:
Diffstat (limited to 'video/out/gl_video.c')
-rw-r--r--video/out/gl_video.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/video/out/gl_video.c b/video/out/gl_video.c
index 067f8f2b1c..5235f1bd1e 100644
--- a/video/out/gl_video.c
+++ b/video/out/gl_video.c
@@ -2440,6 +2440,11 @@ void gl_video_set_output_depth(struct gl_video *p, int r, int g, int b)
struct gl_video *gl_video_init(GL *gl, struct mp_log *log, struct osd_state *osd)
{
+ if (!(gl->mpgl_caps & MPGL_CAP_GL21)) {
+ mp_err(log, "At least OpenGL 2.1 or OpenGL ES 2.0 required.\n");
+ return NULL;
+ }
+
struct gl_video *p = talloc_ptrtype(NULL, p);
*p = (struct gl_video) {
.gl = gl,