Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1028)

Unified Diff: src/gpu/gl/unix/GrGLCreateNativeInterface_unix.cpp

Issue 500153002: Remove reliance on linked in GL functions for assembling GLES interfaces (Closed) Base URL: https://skia.googlesource.com/skia.git@gmcfg
Patch Set: cleanup Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/gpu/gl/unix/GrGLCreateNativeInterface_unix.cpp
diff --git a/src/gpu/gl/unix/GrGLCreateNativeInterface_unix.cpp b/src/gpu/gl/unix/GrGLCreateNativeInterface_unix.cpp
index b3c7a3c5a9d1f1e67c12dba983808bb34a1c9e4a..45c8dc748e92d128a9bd3459c635319c181225a9 100644
--- a/src/gpu/gl/unix/GrGLCreateNativeInterface_unix.cpp
+++ b/src/gpu/gl/unix/GrGLCreateNativeInterface_unix.cpp
@@ -12,15 +12,6 @@
#include <GL/glx.h>
-#define GET_PROC(F) functions->f ## F = (GrGL ## F ## Proc) get(ctx, "gl" #F)
-#define GET_PROC_SUFFIX(F, S) functions->f ## F = (GrGL ## F ## Proc) get(ctx, "gl" #F #S)
-#define GET_PROC_LOCAL(F) GrGL ## F ## Proc F = (GrGL ## F ## Proc) get(ctx, "gl" #F)
-
-#define GET_LINKED GET_PROC
-#define GET_LINKED_SUFFIX GET_PROC_SUFFIX
-
-#include "gl/GrGLAssembleGLESInterface.h"
-
static GrGLFuncPtr glx_get(void* ctx, const char name[]) {
SkASSERT(NULL == ctx);
SkASSERT(NULL != glXGetCurrentContext());
@@ -32,13 +23,5 @@ const GrGLInterface* GrGLCreateNativeInterface() {
return NULL;
}
- const char* verStr = reinterpret_cast<const char*>(glGetString(GR_GL_VERSION));
- GrGLStandard standard = GrGLGetStandardInUseFromString(verStr);
-
- if (kGLES_GrGLStandard == standard) {
- return GrGLAssembleGLESInterface(NULL, glx_get);
- } else if (kGL_GrGLStandard == standard) {
- return GrGLAssembleGLInterface(NULL, glx_get);
- }
- return NULL;
+ return GrGLAssembleInterface(NULL, glx_get);
}

Powered by Google App Engine
This is Rietveld 408576698