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

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

Issue 919683002: Remove canApplyCoverage from XP and all related functions in gpu code. (Closed) Base URL: https://skia.googlesource.com/skia.git@pdDstCopy
Patch Set: Rebase Created 5 years, 10 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/GrContext.cpp » ('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 SK_OVERRIDE { 80 bool supportsRGBCoverage(GrColor knownColor, uint32_t knownColorFlags) const SK_OVERRIDE {
81 return true; 81 return true;
82 } 82 }
83 83
84 bool canApplyCoverage(const GrProcOptInfo& colorPOI,
85 const GrProcOptInfo& coveragePOI) const SK_OVERRIDE {
86 return true;
87 }
88
89 bool canTweakAlphaForCoverage() const SK_OVERRIDE { 84 bool canTweakAlphaForCoverage() const SK_OVERRIDE {
90 return false; 85 return false;
91 } 86 }
92 87
93 void getInvariantOutput(const GrProcOptInfo& colorPOI, const GrProcOptInfo& coveragePOI, 88 void getInvariantOutput(const GrProcOptInfo& colorPOI, const GrProcOptInfo& coveragePOI,
94 GrXPFactory::InvariantOutput*) const SK_OVERRIDE; 89 GrXPFactory::InvariantOutput*) const SK_OVERRIDE;
95 90
96 private: 91 private:
97 GrArithmeticXPFactory(float k1, float k2, float k3, float k4, bool enforcePM Color); 92 GrArithmeticXPFactory(float k1, float k2, float k3, float k4, bool enforcePM Color);
98 93
(...skipping 23 matching lines...) Expand all
122 GR_DECLARE_XP_FACTORY_TEST; 117 GR_DECLARE_XP_FACTORY_TEST;
123 118
124 float fK1, fK2, fK3, fK4; 119 float fK1, fK2, fK3, fK4;
125 bool fEnforcePMColor; 120 bool fEnforcePMColor;
126 121
127 typedef GrXPFactory INHERITED; 122 typedef GrXPFactory INHERITED;
128 }; 123 };
129 124
130 #endif 125 #endif
131 #endif 126 #endif
OLDNEW
« no previous file with comments | « include/gpu/effects/GrPorterDuffXferProcessor.h ('k') | src/gpu/GrContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698