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

Unified Diff: src/effects/SkTableColorFilter.cpp

Issue 1334293003: Create fragment processor for performing input color blend with child processor (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/effects/SkLumaColorFilter.cpp ('k') | src/effects/SkXfermodeImageFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkTableColorFilter.cpp
diff --git a/src/effects/SkTableColorFilter.cpp b/src/effects/SkTableColorFilter.cpp
index 1a2b1343b6232237fa0615ef0cf53b77a8af8bcd..85e3a317bb733708bb8d444959d13474dfc0f6da 100644
--- a/src/effects/SkTableColorFilter.cpp
+++ b/src/effects/SkTableColorFilter.cpp
@@ -49,7 +49,7 @@ public:
#if SK_SUPPORT_GPU
bool asFragmentProcessors(GrContext*, GrProcessorDataManager*,
- SkTDArray<GrFragmentProcessor*>*) const override;
+ SkTDArray<const GrFragmentProcessor*>*) const override;
#endif
void filterSpan(const SkPMColor src[], int count, SkPMColor dst[]) const override;
@@ -521,7 +521,7 @@ bool ColorTableEffect::onIsEqual(const GrFragmentProcessor& other) const {
void ColorTableEffect::onComputeInvariantOutput(GrInvariantOutput* inout) const {
// If we kept the table in the effect then we could actually run known inputs through the
// table.
- uint8_t invalidateFlags = 0;
+ GrColorComponentFlags invalidateFlags = kNone_GrColorComponentFlags;
if (fFlags & SkTable_ColorFilter::kR_Flag) {
invalidateFlags |= kR_GrColorComponentFlag;
}
@@ -563,7 +563,7 @@ const GrFragmentProcessor* ColorTableEffect::TestCreate(GrProcessorTestData* d)
(flags & (1 << 3)) ? luts[3] : nullptr
));
- SkTDArray<GrFragmentProcessor*> array;
+ SkTDArray<const GrFragmentProcessor*> array;
if (filter->asFragmentProcessors(d->fContext, d->fProcDataManager, &array)) {
SkASSERT(1 == array.count()); // TableColorFilter only returns 1
return array[0];
@@ -573,7 +573,7 @@ const GrFragmentProcessor* ColorTableEffect::TestCreate(GrProcessorTestData* d)
bool SkTable_ColorFilter::asFragmentProcessors(GrContext* context,
GrProcessorDataManager*,
- SkTDArray<GrFragmentProcessor*>* array) const {
+ SkTDArray<const GrFragmentProcessor*>* array) const {
SkBitmap bitmap;
this->asComponentTable(&bitmap);
« no previous file with comments | « src/effects/SkLumaColorFilter.cpp ('k') | src/effects/SkXfermodeImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698