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

Side by Side Diff: src/effects/SkArithmeticMode_gpu.h

Issue 1127693002: Remove canTweakAlphaForCoverage from XP's since batch reads flag. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 7 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 | « include/gpu/effects/GrPorterDuffXferProcessor.h ('k') | src/gpu/GrPipelineBuilder.h » ('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 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 #ifndef SkArithmeticMode_gpu_DEFINED 8 #ifndef SkArithmeticMode_gpu_DEFINED
9 #define SkArithmeticMode_gpu_DEFINED 9 #define SkArithmeticMode_gpu_DEFINED
10 10
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 class GrArithmeticXPFactory : public GrXPFactory { 74 class GrArithmeticXPFactory : public GrXPFactory {
75 public: 75 public:
76 static GrXPFactory* Create(float k1, float k2, float k3, float k4, bool enfo rcePMColor) { 76 static GrXPFactory* Create(float k1, float k2, float k3, float k4, bool enfo rcePMColor) {
77 return SkNEW_ARGS(GrArithmeticXPFactory, (k1, k2, k3, k4, enforcePMColor )); 77 return SkNEW_ARGS(GrArithmeticXPFactory, (k1, k2, k3, k4, enforcePMColor ));
78 } 78 }
79 79
80 bool supportsRGBCoverage(GrColor knownColor, uint32_t knownColorFlags) const override { 80 bool supportsRGBCoverage(GrColor knownColor, uint32_t knownColorFlags) const override {
81 return true; 81 return true;
82 } 82 }
83 83
84 bool canTweakAlphaForCoverage() const override {
85 return false;
86 }
87
88 void getInvariantOutput(const GrProcOptInfo& colorPOI, const GrProcOptInfo& coveragePOI, 84 void getInvariantOutput(const GrProcOptInfo& colorPOI, const GrProcOptInfo& coveragePOI,
89 GrXPFactory::InvariantOutput*) const override; 85 GrXPFactory::InvariantOutput*) const override;
90 86
91 private: 87 private:
92 GrArithmeticXPFactory(float k1, float k2, float k3, float k4, bool enforcePM Color); 88 GrArithmeticXPFactory(float k1, float k2, float k3, float k4, bool enforcePM Color);
93 89
94 GrXferProcessor* onCreateXferProcessor(const GrDrawTargetCaps& caps, 90 GrXferProcessor* onCreateXferProcessor(const GrDrawTargetCaps& caps,
95 const GrProcOptInfo& colorPOI, 91 const GrProcOptInfo& colorPOI,
96 const GrProcOptInfo& coveragePOI, 92 const GrProcOptInfo& coveragePOI,
97 const GrDeviceCoordTexture* dstCopy) const override; 93 const GrDeviceCoordTexture* dstCopy) const override;
(...skipping 19 matching lines...) Expand all
117 GR_DECLARE_XP_FACTORY_TEST; 113 GR_DECLARE_XP_FACTORY_TEST;
118 114
119 float fK1, fK2, fK3, fK4; 115 float fK1, fK2, fK3, fK4;
120 bool fEnforcePMColor; 116 bool fEnforcePMColor;
121 117
122 typedef GrXPFactory INHERITED; 118 typedef GrXPFactory INHERITED;
123 }; 119 };
124 120
125 #endif 121 #endif
126 #endif 122 #endif
OLDNEW
« no previous file with comments | « include/gpu/effects/GrPorterDuffXferProcessor.h ('k') | src/gpu/GrPipelineBuilder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698