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

Unified Diff: src/image/SkImageShader.cpp

Issue 1404433002: Remove image usage type enum. Use GrTextureParams instead. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix no gpu build Created 5 years, 2 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/gpu/SkGrPriv.h ('k') | src/image/SkImage_Base.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/image/SkImageShader.cpp
diff --git a/src/image/SkImageShader.cpp b/src/image/SkImageShader.cpp
index cf613e8735343e23a26eec91dbe37e1b0158c60b..56af17994c0a58e5319f44a8570e49e9f7a039f6 100644
--- a/src/image/SkImageShader.cpp
+++ b/src/image/SkImageShader.cpp
@@ -113,17 +113,7 @@ const GrFragmentProcessor* SkImageShader::asFragmentProcessor(GrContext* context
GrTextureParams::FilterMode textureFilterMode =
GrSkFilterQualityToGrFilterMode(filterQuality, viewM, this->getLocalMatrix(), &doBicubic);
GrTextureParams params(tm, textureFilterMode);
-
- SkImageUsageType usageType;
- if (kClamp_TileMode == fTileModeX && kClamp_TileMode == fTileModeY) {
- usageType = kUntiled_SkImageUsageType;
- } else if (GrTextureParams::kNone_FilterMode == textureFilterMode) {
- usageType = kTiled_Unfiltered_SkImageUsageType;
- } else {
- usageType = kTiled_Filtered_SkImageUsageType;
- }
-
- SkAutoTUnref<GrTexture> texture(as_IB(fImage)->asTextureRef(context, usageType));
+ SkAutoTUnref<GrTexture> texture(as_IB(fImage)->asTextureRef(context, params));
if (!texture) {
return nullptr;
}
« no previous file with comments | « src/gpu/SkGrPriv.h ('k') | src/image/SkImage_Base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698