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

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

Issue 851773002: Revert of Switch to a more complete method of filtering hoisted layers (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 11 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 | src/gpu/GrLayerHoister.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 2014 Google Inc. 2 * Copyright 2014 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 GrLayerCache_DEFINED 8 #ifndef GrLayerCache_DEFINED
9 #define GrLayerCache_DEFINED 9 #define GrLayerCache_DEFINED
10 10
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 , fPaint(paint ? SkNEW_ARGS(SkPaint, (*paint)) : NULL) 157 , fPaint(paint ? SkNEW_ARGS(SkPaint, (*paint)) : NULL)
158 , fFilter(NULL) 158 , fFilter(NULL)
159 , fTexture(NULL) 159 , fTexture(NULL)
160 , fRect(SkIRect::MakeEmpty()) 160 , fRect(SkIRect::MakeEmpty())
161 , fPlot(NULL) 161 , fPlot(NULL)
162 , fUses(0) 162 , fUses(0)
163 , fLocked(false) { 163 , fLocked(false) {
164 SkASSERT(SK_InvalidGenID != pictureID); 164 SkASSERT(SK_InvalidGenID != pictureID);
165 165
166 if (fPaint) { 166 if (fPaint) {
167 if (fPaint->getImageFilter()) { 167 if (fPaint->getImageFilter() && fPaint->getImageFilter()->canFilterI mageGPU()) {
168 fFilter = SkSafeRef(fPaint->getImageFilter()); 168 fFilter = SkSafeRef(fPaint->getImageFilter());
169 fPaint->setImageFilter(NULL); 169 fPaint->setImageFilter(NULL);
170 } 170 }
171 } 171 }
172 } 172 }
173 173
174 ~GrCachedLayer() { 174 ~GrCachedLayer() {
175 SkSafeUnref(fTexture); 175 SkSafeUnref(fTexture);
176 SkSafeUnref(fFilter); 176 SkSafeUnref(fFilter);
177 SkDELETE(fPaint); 177 SkDELETE(fPaint);
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
395 SkASSERT(fPlotLocks[plotIdx] > 0); 395 SkASSERT(fPlotLocks[plotIdx] > 0);
396 --fPlotLocks[plotIdx]; 396 --fPlotLocks[plotIdx];
397 } 397 }
398 398
399 // for testing 399 // for testing
400 friend class TestingAccess; 400 friend class TestingAccess;
401 int numLayers() const { return fLayerHash.count(); } 401 int numLayers() const { return fLayerHash.count(); }
402 }; 402 };
403 403
404 #endif 404 #endif
OLDNEW
« no previous file with comments | « no previous file | src/gpu/GrLayerHoister.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698