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

Unified Diff: Source/core/platform/graphics/Image.cpp

Issue 15466003: Remove image decoder down sampling (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove virtual setSize() from GIF decoder Created 7 years, 7 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 | « Source/core/platform/graphics/Image.h ('k') | Source/core/platform/graphics/ImageSource.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/platform/graphics/Image.cpp
diff --git a/Source/core/platform/graphics/Image.cpp b/Source/core/platform/graphics/Image.cpp
index 567b260105c5af29f95623969cd8fd699b71dca9..122f9bec54dbb26757f6f1e156ed4f08f25278a5 100644
--- a/Source/core/platform/graphics/Image.cpp
+++ b/Source/core/platform/graphics/Image.cpp
@@ -183,23 +183,6 @@ void Image::drawTiled(GraphicsContext* ctxt, const FloatRect& dstRect, const Flo
startAnimation();
}
-#if ENABLE(IMAGE_DECODER_DOWN_SAMPLING)
-FloatRect Image::adjustSourceRectForDownSampling(const FloatRect& srcRect, const IntSize& scaledSize) const
-{
- const IntSize unscaledSize = size();
- if (unscaledSize == scaledSize)
- return srcRect;
-
- // Image has been down-sampled.
- float xscale = static_cast<float>(scaledSize.width()) / unscaledSize.width();
- float yscale = static_cast<float>(scaledSize.height()) / unscaledSize.height();
- FloatRect scaledSrcRect = srcRect;
- scaledSrcRect.scale(xscale, yscale);
-
- return scaledSrcRect;
-}
-#endif
-
void Image::computeIntrinsicDimensions(Length& intrinsicWidth, Length& intrinsicHeight, FloatSize& intrinsicRatio)
{
intrinsicRatio = size();
« no previous file with comments | « Source/core/platform/graphics/Image.h ('k') | Source/core/platform/graphics/ImageSource.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698