aboutsummaryrefslogtreecommitdiff
path: root/render/gles2/renderer.c
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-10-08 10:04:33 -0400
committerGitHub <noreply@github.com>2017-10-08 10:04:33 -0400
commit1908d88fab23660e863928d8fc874bad4593b087 (patch)
tree6c04d433e9a1203554639d21fad3f1197cef5cee /render/gles2/renderer.c
parent2f36e78de1da5ca8ef3a975674b02bcc988cd06a (diff)
parentc0e5feea37dbc95675face03bc4707ad09db20b8 (diff)
Merge pull request #236 from ascent12/gl-loader
Add GL/EGL extension loader generator
Diffstat (limited to 'render/gles2/renderer.c')
-rw-r--r--render/gles2/renderer.c20
1 files changed, 1 insertions, 19 deletions
diff --git a/render/gles2/renderer.c b/render/gles2/renderer.c
index d6c22ebe..325e1571 100644
--- a/render/gles2/renderer.c
+++ b/render/gles2/renderer.c
@@ -12,8 +12,8 @@
#include <wlr/render/matrix.h>
#include <wlr/util/log.h>
#include "render/gles2.h"
+#include "render/glapi.h"
-PFNGLEGLIMAGETARGETTEXTURE2DOESPROC glEGLImageTargetTexture2DOES = NULL;
struct shaders shaders;
static bool compile_shader(GLuint type, const GLchar *src, GLuint *shader) {
@@ -101,25 +101,7 @@ error:
wlr_log(L_ERROR, "Failed to set up default shaders!");
}
-static void init_image_ext() {
- if (glEGLImageTargetTexture2DOES) {
- return;
- }
-
- const char *exts = (const char*) glGetString(GL_EXTENSIONS);
- if (strstr(exts, "GL_OES_EGL_image_external")) {
- glEGLImageTargetTexture2DOES = (PFNGLEGLIMAGETARGETTEXTURE2DOESPROC)
- eglGetProcAddress("glEGLImageTargetTexture2DOES");
- }
-
- if (!glEGLImageTargetTexture2DOES) {
- wlr_log(L_INFO, "Failed to load glEGLImageTargetTexture2DOES "
- "Will not be able to attach drm buffers");
- }
-}
-
static void init_globals() {
- init_image_ext();
init_default_shaders();
}