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

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

Issue 16180006: separate arrays for color and coverage effects. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: add helper function Created 7 years, 6 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/GrGLProgramDesc.cpp ('k') | src/gpu/gl/GrGpuGL_program.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 9
10 #ifndef GrGpuGL_DEFINED 10 #ifndef GrGpuGL_DEFINED
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 const GrGLContext& glContext() const { return fGLContext; } 171 const GrGLContext& glContext() const { return fGLContext; }
172 172
173 static bool BlendCoeffReferencesConstant(GrBlendCoeff coeff); 173 static bool BlendCoeffReferencesConstant(GrBlendCoeff coeff);
174 174
175 class ProgramCache : public ::GrNoncopyable { 175 class ProgramCache : public ::GrNoncopyable {
176 public: 176 public:
177 ProgramCache(const GrGLContext& gl); 177 ProgramCache(const GrGLContext& gl);
178 ~ProgramCache(); 178 ~ProgramCache();
179 179
180 void abandon(); 180 void abandon();
181 GrGLProgram* getProgram(const GrGLProgramDesc& desc, const GrEffectStage * stages[]); 181 GrGLProgram* getProgram(const GrGLProgramDesc& desc,
182 const GrEffectStage* colorStages[],
183 const GrEffectStage* coverageStages[]);
182 184
183 private: 185 private:
184 enum { 186 enum {
185 // We may actually have kMaxEntries+1 shaders in the GL context beca use we create a new 187 // We may actually have kMaxEntries+1 shaders in the GL context beca use we create a new
186 // shader before evicting from the cache. 188 // shader before evicting from the cache.
187 kMaxEntries = 32, 189 kMaxEntries = 32,
188 kHashBits = 6, 190 kHashBits = 6,
189 }; 191 };
190 192
191 struct Entry; 193 struct Entry;
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 ///@} 433 ///@}
432 434
433 // we record what stencil format worked last time to hopefully exit early 435 // we record what stencil format worked last time to hopefully exit early
434 // from our loop that tries stencil formats and calls check fb status. 436 // from our loop that tries stencil formats and calls check fb status.
435 int fLastSuccessfulStencilFmtIdx; 437 int fLastSuccessfulStencilFmtIdx;
436 438
437 typedef GrGpu INHERITED; 439 typedef GrGpu INHERITED;
438 }; 440 };
439 441
440 #endif 442 #endif
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLProgramDesc.cpp ('k') | src/gpu/gl/GrGpuGL_program.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698