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

Side by Side Diff: src/gpu/GrBatch.h

Issue 1275083002: Don't pass pipeline to GrBatch::generateGeometry() (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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
« no previous file with comments | « src/gpu/GrAtlasTextContext.cpp ('k') | src/gpu/GrDefaultPathRenderer.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 2015 Google Inc. 2 * Copyright 2015 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 #ifndef GrBatch_DEFINED 8 #ifndef GrBatch_DEFINED
9 #define GrBatch_DEFINED 9 #define GrBatch_DEFINED
10 10
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 bool combineIfPossible(GrBatch* that) { 55 bool combineIfPossible(GrBatch* that) {
56 if (this->classID() != that->classID()) { 56 if (this->classID() != that->classID()) {
57 return false; 57 return false;
58 } 58 }
59 59
60 return this->onCombineIfPossible(that); 60 return this->onCombineIfPossible(that);
61 } 61 }
62 62
63 virtual bool onCombineIfPossible(GrBatch*) = 0; 63 virtual bool onCombineIfPossible(GrBatch*) = 0;
64 64
65 virtual void generateGeometry(GrBatchTarget*, const GrPipeline*) = 0; 65 virtual void generateGeometry(GrBatchTarget*) = 0;
66 66
67 const SkRect& bounds() const { return fBounds; } 67 const SkRect& bounds() const { return fBounds; }
68 68
69 // TODO this goes away when batches are everywhere 69 // TODO this goes away when batches are everywhere
70 void setNumberOfDraws(int numberOfDraws) { fNumberOfDraws = numberOfDraws; } 70 void setNumberOfDraws(int numberOfDraws) { fNumberOfDraws = numberOfDraws; }
71 int numberOfDraws() const { return fNumberOfDraws; } 71 int numberOfDraws() const { return fNumberOfDraws; }
72 72
73 void* operator new(size_t size); 73 void* operator new(size_t size);
74 void operator delete(void* target); 74 void operator delete(void* target);
75 75
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 }; 169 };
170 SkAutoTUnref<const GrPipeline> fPipeline; 170 SkAutoTUnref<const GrPipeline> fPipeline;
171 static int32_t gCurrBatchClassID; 171 static int32_t gCurrBatchClassID;
172 int fNumberOfDraws; 172 int fNumberOfDraws;
173 SkDEBUGCODE(bool fUsed;) 173 SkDEBUGCODE(bool fUsed;)
174 174
175 typedef SkRefCnt INHERITED; 175 typedef SkRefCnt INHERITED;
176 }; 176 };
177 177
178 #endif 178 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrAtlasTextContext.cpp ('k') | src/gpu/GrDefaultPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698