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

Unified Diff: Source/platform/graphics/GraphicsContext.cpp

Issue 1187473011: SP: Use a high-quality image filter regardless of CTM. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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 | « no previous file | Source/platform/graphics/skia/SkiaUtils.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/graphics/GraphicsContext.cpp
diff --git a/Source/platform/graphics/GraphicsContext.cpp b/Source/platform/graphics/GraphicsContext.cpp
index 467535d2c075f696d1d17cb038346e21db60a3e3..1a9c1b2e610872a9ec3dd8ae53b5c110b1d52a20 100644
--- a/Source/platform/graphics/GraphicsContext.cpp
+++ b/Source/platform/graphics/GraphicsContext.cpp
@@ -956,15 +956,8 @@ SkFilterQuality GraphicsContext::computeFilterQuality(Image* image, const FloatR
} else if (image->isLazyDecodedBitmap()) {
resampling = InterpolationHigh;
} else {
- // Take into account scale applied to the canvas when computing sampling mode (e.g. CSS scale or page scale).
- // FIXME: In slimming paint, we create GCs on the fly when entering a new DisplayItemList
- // scope, so relying on getTotalMatrix here is not sound.
SkRect destRectTarget = dest;
- SkMatrix totalMatrix = getTotalMatrix();
- if (!(totalMatrix.getType() & (SkMatrix::kAffine_Mask | SkMatrix::kPerspective_Mask)))
- totalMatrix.mapRect(&destRectTarget, dest);
-
- resampling = computeInterpolationQuality(totalMatrix,
+ resampling = computeInterpolationQuality(
SkScalarToFloat(src.width()), SkScalarToFloat(src.height()),
SkScalarToFloat(destRectTarget.width()), SkScalarToFloat(destRectTarget.height()),
image->isImmutableBitmap());
« no previous file with comments | « no previous file | Source/platform/graphics/skia/SkiaUtils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698