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

Unified Diff: src/gpu/gl/GrGLExtensions.cpp

Issue 23359002: Use indexed extensions on ES3. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 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
« no previous file with comments | « no previous file | src/gpu/gl/GrGLInterface.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGLExtensions.cpp
===================================================================
--- src/gpu/gl/GrGLExtensions.cpp (revision 10811)
+++ src/gpu/gl/GrGLExtensions.cpp (working copy)
@@ -26,15 +26,15 @@
if (NULL == getString) {
return false;
}
- bool indexed = false;
- if (kDesktop_GrGLBinding == binding) {
- const GrGLubyte* verString = getString(GR_GL_VERSION);
- if (NULL == verString) {
- return false;
- }
- GrGLVersion version = GrGLGetVersionFromString((const char*) verString);
- indexed = version >= GR_GL_VER(3, 0);
+
+ // glGetStringi and indexed extensions were added in version 3.0 of desktop GL and ES.
+ const GrGLubyte* verString = getString(GR_GL_VERSION);
+ if (NULL == verString) {
+ return false;
}
+ GrGLVersion version = GrGLGetVersionFromString((const char*) verString);
+ bool indexed = version >= GR_GL_VER(3, 0);
+
if (indexed) {
if (NULL == getStringi || NULL == getIntegerv) {
return false;
« no previous file with comments | « no previous file | src/gpu/gl/GrGLInterface.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698