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

Side by Side Diff: src/gpu/gl/GrGLUtil.cpp

Issue 23185004: Rename kES2_GrGLBinding to kES_GrGLBinding. Step 0 for supporting ES3. (Closed) Base URL: https://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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/gpu/gl/GrGLShaderVar.h ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 8
9 #include "GrGLUtil.h" 9 #include "GrGLUtil.h"
10 10
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 char profile[2]; 109 char profile[2];
110 n = sscanf(versionString, "OpenGL ES-%c%c %d.%d", profile, profile+1, &major , &minor); 110 n = sscanf(versionString, "OpenGL ES-%c%c %d.%d", profile, profile+1, &major , &minor);
111 if (4 == n) { 111 if (4 == n) {
112 // we no longer support ES1. 112 // we no longer support ES1.
113 return kNone_GrGLBinding; 113 return kNone_GrGLBinding;
114 } 114 }
115 115
116 // check for ES2 116 // check for ES2
117 n = sscanf(versionString, "OpenGL ES %d.%d", &major, &minor); 117 n = sscanf(versionString, "OpenGL ES %d.%d", &major, &minor);
118 if (2 == n) { 118 if (2 == n) {
119 return kES2_GrGLBinding; 119 return kES_GrGLBinding;
120 } 120 }
121 return kNone_GrGLBinding; 121 return kNone_GrGLBinding;
122 } 122 }
123 123
124 bool GrGLIsMesaFromVersionString(const char* versionString) { 124 bool GrGLIsMesaFromVersionString(const char* versionString) {
125 int major, minor, mesaMajor, mesaMinor; 125 int major, minor, mesaMajor, mesaMinor;
126 int n = sscanf(versionString, "%d.%d Mesa %d.%d", &major, &minor, &mesaMajor , &mesaMinor); 126 int n = sscanf(versionString, "%d.%d Mesa %d.%d", &major, &minor, &mesaMajor , &mesaMinor);
127 return 4 == n; 127 return 4 == n;
128 } 128 }
129 129
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 const GrGLubyte* v; 226 const GrGLubyte* v;
227 GR_GL_CALL_RET(gl, v, GetString(GR_GL_SHADING_LANGUAGE_VERSION)); 227 GR_GL_CALL_RET(gl, v, GetString(GR_GL_SHADING_LANGUAGE_VERSION));
228 return GrGLGetGLSLVersionFromString((const char*) v); 228 return GrGLGetGLSLVersionFromString((const char*) v);
229 } 229 }
230 230
231 GrGLVendor GrGLGetVendor(const GrGLInterface* gl) { 231 GrGLVendor GrGLGetVendor(const GrGLInterface* gl) {
232 const GrGLubyte* v; 232 const GrGLubyte* v;
233 GR_GL_CALL_RET(gl, v, GetString(GR_GL_VENDOR)); 233 GR_GL_CALL_RET(gl, v, GetString(GR_GL_VENDOR));
234 return GrGLGetVendorFromString((const char*) v); 234 return GrGLGetVendorFromString((const char*) v);
235 } 235 }
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLShaderVar.h ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698