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

Side by Side Diff: gpu/command_buffer/client/gles2_demo_cc.cc

Issue 518011: linux: gles2 client fixes (Closed)
Patch Set: Created 10 years, 12 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
« no previous file with comments | « no previous file | gpu/command_buffer/client/gles2_implementation.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file is here so other GLES2 related files can have a common set of 5 // This file is here so other GLES2 related files can have a common set of
6 // includes where appropriate. 6 // includes where appropriate.
7 7
8 #include <GLES2/gl2.h> 8 #include <GLES2/gl2.h>
9 #include "gpu/command_buffer/client/gles2_demo_cc.h" 9 #include "gpu/command_buffer/client/gles2_demo_cc.h"
10 10
11 namespace { 11 namespace {
12 12
13 int g_width = 512;
14 int g_height = 512;
15 GLuint g_texture = 0; 13 GLuint g_texture = 0;
16 int g_textureLoc = -1; 14 int g_textureLoc = -1;
17 GLuint g_programObject = 0; 15 GLuint g_programObject = 0;
18 GLuint g_vbo = 0; 16 GLuint g_vbo = 0;
19 GLsizei g_texCoordOffset = 0; 17 GLsizei g_texCoordOffset = 0;
20 18
21 void CheckGLError() { 19 void CheckGLError() {
22 GLenum error = glGetError(); 20 GLenum error = glGetError();
23 if (error != GL_NO_ERROR) { 21 if (error != GL_NO_ERROR) {
24 DLOG(ERROR) << "GL Error: " << error; 22 DLOG(ERROR) << "GL Error: " << error;
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 } // anonymous namespace. 180 } // anonymous namespace.
183 181
184 void GLFromCPPTestFunction() { 182 void GLFromCPPTestFunction() {
185 static bool initialized = false; 183 static bool initialized = false;
186 if (!initialized) { 184 if (!initialized) {
187 initialized = true; 185 initialized = true;
188 Init(); 186 Init();
189 } 187 }
190 Draw(); 188 Draw();
191 } 189 }
192
193
194
OLDNEW
« no previous file with comments | « no previous file | gpu/command_buffer/client/gles2_implementation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698