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

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

Issue 23636011: Add a GrGpuGL reference for GrGLProgram/GrGLUniformManager (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 3 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
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 "GrGpuGL.h" 9 #include "GrGpuGL.h"
10 #include "GrGLStencilBuffer.h" 10 #include "GrGLStencilBuffer.h"
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 this); 141 this);
142 GrPrintf("------ VENDOR %s\n", vendor); 142 GrPrintf("------ VENDOR %s\n", vendor);
143 GrPrintf("------ RENDERER %s\n", renderer); 143 GrPrintf("------ RENDERER %s\n", renderer);
144 GrPrintf("------ VERSION %s\n", version); 144 GrPrintf("------ VERSION %s\n", version);
145 GrPrintf("------ EXTENSIONS\n"); 145 GrPrintf("------ EXTENSIONS\n");
146 ctx.info().extensions().print(); 146 ctx.info().extensions().print();
147 GrPrintf("\n"); 147 GrPrintf("\n");
148 ctx.info().caps()->print(); 148 ctx.info().caps()->print();
149 } 149 }
150 150
151 fProgramCache = SkNEW_ARGS(ProgramCache, (this->glContext())); 151 fProgramCache = SkNEW_ARGS(ProgramCache, (this));
152 152
153 SkASSERT(this->glCaps().maxVertexAttributes() >= GrDrawState::kMaxVertexAttr ibCnt); 153 SkASSERT(this->glCaps().maxVertexAttributes() >= GrDrawState::kMaxVertexAttr ibCnt);
154 154
155 fLastSuccessfulStencilFmtIdx = 0; 155 fLastSuccessfulStencilFmtIdx = 0;
156 fHWProgramID = 0; 156 fHWProgramID = 0;
157 } 157 }
158 158
159 GrGpuGL::~GrGpuGL() { 159 GrGpuGL::~GrGpuGL() {
160 if (0 != fHWProgramID) { 160 if (0 != fHWProgramID) {
161 // detach the current program so there is no confusion on OpenGL's part 161 // detach the current program so there is no confusion on OpenGL's part
(...skipping 2416 matching lines...) Expand 10 before | Expand all | Expand 10 after
2578 this->setVertexArrayID(gpu, 0); 2578 this->setVertexArrayID(gpu, 0);
2579 } 2579 }
2580 int attrCount = gpu->glCaps().maxVertexAttributes(); 2580 int attrCount = gpu->glCaps().maxVertexAttributes();
2581 if (fDefaultVertexArrayAttribState.count() != attrCount) { 2581 if (fDefaultVertexArrayAttribState.count() != attrCount) {
2582 fDefaultVertexArrayAttribState.resize(attrCount); 2582 fDefaultVertexArrayAttribState.resize(attrCount);
2583 } 2583 }
2584 attribState = &fDefaultVertexArrayAttribState; 2584 attribState = &fDefaultVertexArrayAttribState;
2585 } 2585 }
2586 return attribState; 2586 return attribState;
2587 } 2587 }
OLDNEW
« src/gpu/gl/GrGpuGL.h ('K') | « src/gpu/gl/GrGpuGL.h ('k') | src/gpu/gl/GrGpuGL_program.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698