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

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

Issue 1845283003: Gamma-correctness pushed into Skia, top-down. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Rebase 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 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 #include "GrPipelineBuilder.h" 8 #include "GrPipelineBuilder.h"
9 9
10 #include "GrBlend.h" 10 #include "GrBlend.h"
(...skipping 28 matching lines...) Expand all
39 fDrawFace = kBoth_DrawFace; 39 fDrawFace = kBoth_DrawFace;
40 fStencilSettings.setDisabled(); 40 fStencilSettings.setDisabled();
41 fFlags = 0; 41 fFlags = 0;
42 42
43 fClip = clip; 43 fClip = clip;
44 44
45 this->setState(GrPipelineBuilder::kHWAntialias_Flag, 45 this->setState(GrPipelineBuilder::kHWAntialias_Flag,
46 rt->isUnifiedMultisampled() && paint.isAntiAlias()); 46 rt->isUnifiedMultisampled() && paint.isAntiAlias());
47 this->setState(GrPipelineBuilder::kDisableOutputConversionToSRGB_Flag, 47 this->setState(GrPipelineBuilder::kDisableOutputConversionToSRGB_Flag,
48 paint.getDisableOutputConversionToSRGB()); 48 paint.getDisableOutputConversionToSRGB());
49 this->setState(GrPipelineBuilder::kAllowSRGBInputs_Flag,
50 paint.getAllowSRGBInputs());
49 } 51 }
50 52
51 //////////////////////////////////////////////////////////////////////////////s 53 //////////////////////////////////////////////////////////////////////////////s
52 54
53 bool GrPipelineBuilder::willXPNeedDstTexture(const GrCaps& caps, 55 bool GrPipelineBuilder::willXPNeedDstTexture(const GrCaps& caps,
54 const GrPipelineOptimizations& opti mizations) const { 56 const GrPipelineOptimizations& opti mizations) const {
55 if (this->getXPFactory()) { 57 if (this->getXPFactory()) {
56 return this->getXPFactory()->willNeedDstTexture(caps, optimizations, 58 return this->getXPFactory()->willNeedDstTexture(caps, optimizations,
57 this->hasMixedSamples()) ; 59 this->hasMixedSamples()) ;
58 } 60 }
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 92
91 GrPipelineBuilder::~GrPipelineBuilder() { 93 GrPipelineBuilder::~GrPipelineBuilder() {
92 SkASSERT(0 == fBlockEffectRemovalCnt); 94 SkASSERT(0 == fBlockEffectRemovalCnt);
93 for (int i = 0; i < fColorFragmentProcessors.count(); ++i) { 95 for (int i = 0; i < fColorFragmentProcessors.count(); ++i) {
94 fColorFragmentProcessors[i]->unref(); 96 fColorFragmentProcessors[i]->unref();
95 } 97 }
96 for (int i = 0; i < fCoverageFragmentProcessors.count(); ++i) { 98 for (int i = 0; i < fCoverageFragmentProcessors.count(); ++i) {
97 fCoverageFragmentProcessors[i]->unref(); 99 fCoverageFragmentProcessors[i]->unref();
98 } 100 }
99 } 101 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698