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

Side by Side Diff: src/gpu/GrClipMaskManager.cpp

Issue 1415413007: Revert of Fix up the clip mask manager's creation of paths (w.r.t. volatility) (Closed) Base URL: https://skia.googlesource.com/skia.git@mdb-simplify-cmm
Patch Set: Created 5 years, 1 month 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/core/SkClipStack.cpp ('k') | no next file » | 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 2012 Google Inc. 2 * Copyright 2012 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 #include "GrClipMaskManager.h" 8 #include "GrClipMaskManager.h"
9 #include "GrCaps.h" 9 #include "GrCaps.h"
10 #include "GrDrawContext.h" 10 #include "GrDrawContext.h"
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after
441 fDrawTarget->drawAARect(*pipelineBuilder, color, viewMatrix, 441 fDrawTarget->drawAARect(*pipelineBuilder, color, viewMatrix,
442 element->getRect(), devRect); 442 element->getRect(), devRect);
443 } else { 443 } else {
444 fDrawTarget->drawNonAARect(*pipelineBuilder, color, viewMatrix, 444 fDrawTarget->drawNonAARect(*pipelineBuilder, color, viewMatrix,
445 element->getRect()); 445 element->getRect());
446 } 446 }
447 return true; 447 return true;
448 default: { 448 default: {
449 SkPath path; 449 SkPath path;
450 element->asPath(&path); 450 element->asPath(&path);
451 path.setIsVolatile(true);
451 if (path.isInverseFillType()) { 452 if (path.isInverseFillType()) {
452 path.toggleInverseFillType(); 453 path.toggleInverseFillType();
453 } 454 }
454 GrStrokeInfo stroke(SkStrokeRec::kFill_InitStyle); 455 GrStrokeInfo stroke(SkStrokeRec::kFill_InitStyle);
455 if (nullptr == pr) { 456 if (nullptr == pr) {
456 GrPathRendererChain::DrawType type; 457 GrPathRendererChain::DrawType type;
457 type = element->isAA() ? GrPathRendererChain::kColorAntiAlias_Dr awType : 458 type = element->isAA() ? GrPathRendererChain::kColorAntiAlias_Dr awType :
458 GrPathRendererChain::kColor_DrawType; 459 GrPathRendererChain::kColor_DrawType;
459 pr = this->getContext()->getPathRenderer(*pipelineBuilder, viewM atrix, 460 pr = this->getContext()->getPathRenderer(*pipelineBuilder, viewM atrix,
460 path, stroke, false, ty pe); 461 path, stroke, false, ty pe);
(...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after
1135 1136
1136 //////////////////////////////////////////////////////////////////////////////// 1137 ////////////////////////////////////////////////////////////////////////////////
1137 1138
1138 void GrClipMaskManager::adjustPathStencilParams(const GrStencilAttachment* stenc ilAttachment, 1139 void GrClipMaskManager::adjustPathStencilParams(const GrStencilAttachment* stenc ilAttachment,
1139 GrStencilSettings* settings) { 1140 GrStencilSettings* settings) {
1140 if (stencilAttachment) { 1141 if (stencilAttachment) {
1141 int stencilBits = stencilAttachment->bits(); 1142 int stencilBits = stencilAttachment->bits();
1142 this->adjustStencilParams(settings, fClipMode, stencilBits); 1143 this->adjustStencilParams(settings, fClipMode, stencilBits);
1143 } 1144 }
1144 } 1145 }
OLDNEW
« no previous file with comments | « src/core/SkClipStack.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698