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

Side by Side Diff: src/gpu/GrPipeline.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 "GrPipeline.h" 8 #include "GrPipeline.h"
9 9
10 #include "GrCaps.h" 10 #include "GrCaps.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 pipeline->fFlags = 0; 77 pipeline->fFlags = 0;
78 if (builder.isHWAntialias()) { 78 if (builder.isHWAntialias()) {
79 pipeline->fFlags |= kHWAA_Flag; 79 pipeline->fFlags |= kHWAA_Flag;
80 } 80 }
81 if (builder.snapVerticesToPixelCenters()) { 81 if (builder.snapVerticesToPixelCenters()) {
82 pipeline->fFlags |= kSnapVertices_Flag; 82 pipeline->fFlags |= kSnapVertices_Flag;
83 } 83 }
84 if (builder.getDisableOutputConversionToSRGB()) { 84 if (builder.getDisableOutputConversionToSRGB()) {
85 pipeline->fFlags |= kDisableOutputConversionToSRGB_Flag; 85 pipeline->fFlags |= kDisableOutputConversionToSRGB_Flag;
86 } 86 }
87 if (builder.getAllowSRGBInputs()) {
88 pipeline->fFlags |= kAllowSRGBInputs_Flag;
89 }
87 90
88 int firstColorProcessorIdx = args.fOpts.fColorPOI.firstEffectiveProcessorInd ex(); 91 int firstColorProcessorIdx = args.fOpts.fColorPOI.firstEffectiveProcessorInd ex();
89 92
90 // TODO: Once we can handle single or four channel input into coverage GrFra gmentProcessors 93 // TODO: Once we can handle single or four channel input into coverage GrFra gmentProcessors
91 // then we can use GrPipelineBuilder's coverageProcInfo (like color above) t o set this initial 94 // then we can use GrPipelineBuilder's coverageProcInfo (like color above) t o set this initial
92 // information. 95 // information.
93 int firstCoverageProcessorIdx = 0; 96 int firstCoverageProcessorIdx = 0;
94 97
95 pipeline->adjustProgramFromOptimizations(builder, optFlags, args.fOpts.fColo rPOI, 98 pipeline->adjustProgramFromOptimizations(builder, optFlags, args.fOpts.fColo rPOI,
96 args.fOpts.fCoveragePOI, &firstColo rProcessorIdx, 99 args.fOpts.fCoveragePOI, &firstColo rProcessorIdx,
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 } 224 }
222 } 225 }
223 226
224 for (int i = 0; i < a.numFragmentProcessors(); i++) { 227 for (int i = 0; i < a.numFragmentProcessors(); i++) {
225 if (!a.getFragmentProcessor(i).isEqual(b.getFragmentProcessor(i), ignore CoordTransforms)) { 228 if (!a.getFragmentProcessor(i).isEqual(b.getFragmentProcessor(i), ignore CoordTransforms)) {
226 return false; 229 return false;
227 } 230 }
228 } 231 }
229 return true; 232 return true;
230 } 233 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698