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

Unified Diff: src/effects/SkMorphologyImageFilter.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 side-by-side diff with in-line comments
Download patch
Index: src/effects/SkMorphologyImageFilter.cpp
diff --git a/src/effects/SkMorphologyImageFilter.cpp b/src/effects/SkMorphologyImageFilter.cpp
index ea714e59f69b1579bc26d2e87c95c8c58915a6f5..616c0d2e8b23e9ab036360621aca796c67206109 100644
--- a/src/effects/SkMorphologyImageFilter.cpp
+++ b/src/effects/SkMorphologyImageFilter.cpp
@@ -370,6 +370,7 @@ static void apply_morphology_rect(GrDrawContext* drawContext,
float bounds[2],
Gr1DKernelEffect::Direction direction) {
GrPaint paint;
+ // SRGBTODO: AllowSRGBInputs?
bsalomon 2016/04/06 13:19:28 probably should depend on the drawContext at the r
paint.addColorFragmentProcessor(GrMorphologyEffect::Create(texture,
direction,
radius,
@@ -389,6 +390,7 @@ static void apply_morphology_rect_no_bounds(GrDrawContext* drawContext,
GrMorphologyEffect::MorphologyType morphType,
Gr1DKernelEffect::Direction direction) {
GrPaint paint;
+ // SRGBTODO: AllowSRGBInputs?
bsalomon 2016/04/06 13:19:28 ditto
paint.addColorFragmentProcessor(GrMorphologyEffect::Create(texture,
direction,
radius,
@@ -511,7 +513,7 @@ static sk_sp<SkSpecialImage> apply_morphology(SkSpecialImage* input,
return SkSpecialImage::MakeFromGpu(input->internal_getProxy(),
SkIRect::MakeWH(rect.width(), rect.height()),
kNeedNewImageUniqueID_SpecialImage,
- srcTexture);
+ srcTexture, &input->props());
}
#endif
@@ -619,5 +621,5 @@ sk_sp<SkSpecialImage> SkMorphologyImageFilter::onFilterImage(SkSpecialImage* sou
return SkSpecialImage::MakeFromRaster(source->internal_getProxy(),
SkIRect::MakeWH(bounds.width(), bounds.height()),
- dst);
+ dst, &source->props());
}

Powered by Google App Engine
This is Rietveld 408576698