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

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

Issue 1845283003: Gamma-correctness pushed into Skia, top-down. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove helper function for old pixel-config method of enabling decode Created 4 years, 8 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
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 "GrDrawingManager.h" 10 #include "GrDrawingManager.h"
(...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after
699 if (!dc->drawContextPriv().drawAndStencilRect(&maskSpaceIBounds, kDr awOutsideElement, 699 if (!dc->drawContextPriv().drawAndStencilRect(&maskSpaceIBounds, kDr awOutsideElement,
700 op, !invert, false, 700 op, !invert, false,
701 translate, 701 translate,
702 SkRect::Make(clipSpace IBounds))) { 702 SkRect::Make(clipSpace IBounds))) {
703 texture->resourcePriv().removeUniqueKey(); 703 texture->resourcePriv().removeUniqueKey();
704 return nullptr; 704 return nullptr;
705 } 705 }
706 } else { 706 } else {
707 // all the remaining ops can just be directly draw into the accumula tion buffer 707 // all the remaining ops can just be directly draw into the accumula tion buffer
708 GrPaint paint; 708 GrPaint paint;
709 // SRGBTODO: AllowSRGBInputs?
bsalomon 2016/04/05 13:24:01 This is drawing clips as coverage masks, no need f
Brian Osman 2016/04/05 15:36:41 Acknowledged.
709 paint.setAntiAlias(element->isAA()); 710 paint.setAntiAlias(element->isAA());
710 paint.setCoverageSetOpXPFactory(op, false); 711 paint.setCoverageSetOpXPFactory(op, false);
711 712
712 draw_element(dc, GrClip::WideOpen(), paint, translate, element); 713 draw_element(dc, GrClip::WideOpen(), paint, translate, element);
713 } 714 }
714 } 715 }
715 716
716 return texture.release(); 717 return texture.release();
717 } 718 }
718 719
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after
1154 1155
1155 //////////////////////////////////////////////////////////////////////////////// 1156 ////////////////////////////////////////////////////////////////////////////////
1156 1157
1157 void GrClipMaskManager::adjustPathStencilParams(const GrStencilAttachment* stenc ilAttachment, 1158 void GrClipMaskManager::adjustPathStencilParams(const GrStencilAttachment* stenc ilAttachment,
1158 GrStencilSettings* settings) { 1159 GrStencilSettings* settings) {
1159 if (stencilAttachment) { 1160 if (stencilAttachment) {
1160 int stencilBits = stencilAttachment->bits(); 1161 int stencilBits = stencilAttachment->bits();
1161 this->adjustStencilParams(settings, fClipMode, stencilBits); 1162 this->adjustStencilParams(settings, fClipMode, stencilBits);
1162 } 1163 }
1163 } 1164 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698