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

Unified Diff: src/core/SkSpecialImage.cpp

Issue 2037413002: Add SkSourceGammaTreatment enum so we know how to create mips (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Fix DM compilation Created 4 years, 6 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/core/SkShader.cpp ('k') | src/effects/SkPerlinNoiseShader.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkSpecialImage.cpp
diff --git a/src/core/SkSpecialImage.cpp b/src/core/SkSpecialImage.cpp
index 420b3f1e2336998afa571b2f6c5e40b603dc009e..081b2a5b765ed560a915c917af557ff39963ed06 100644
--- a/src/core/SkSpecialImage.cpp
+++ b/src/core/SkSpecialImage.cpp
@@ -84,7 +84,8 @@ sk_sp<SkSpecialImage> SkSpecialImage::makeTextureImage(GrContext* context) {
sk_sp<GrTexture> resultTex(GrRefCachedBitmapTexture(context,
bmp,
- GrTextureParams::ClampNoFilter()));
+ GrTextureParams::ClampNoFilter(),
+ SkSourceGammaTreatment::kRespect));
if (!resultTex) {
return nullptr;
}
@@ -226,7 +227,8 @@ public:
#if SK_SUPPORT_GPU
sk_sp<GrTexture> onAsTextureRef(GrContext* context) const override {
return sk_sp<GrTexture>(as_IB(fImage)->asTextureRef(context,
- GrTextureParams::ClampNoFilter()));
+ GrTextureParams::ClampNoFilter(),
+ SkSourceGammaTreatment::kRespect));
}
#endif
@@ -368,7 +370,8 @@ public:
if (context) {
return sk_ref_sp(GrRefCachedBitmapTexture(context,
fBitmap,
- GrTextureParams::ClampNoFilter()));
+ GrTextureParams::ClampNoFilter(),
+ SkSourceGammaTreatment::kRespect));
}
return nullptr;
« no previous file with comments | « src/core/SkShader.cpp ('k') | src/effects/SkPerlinNoiseShader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698