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

Unified Diff: Source/core/platform/image-decoders/webp/WEBPImageDecoder.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/image-decoders/png/PNGImageDecoder.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/platform/image-decoders/webp/WEBPImageDecoder.cpp
diff --git a/Source/core/platform/image-decoders/webp/WEBPImageDecoder.cpp b/Source/core/platform/image-decoders/webp/WEBPImageDecoder.cpp
index 3c905a94441119725907fd792cde5bf8a778daad..26171f55dae281d37ebcb21ce8f08c8b957750ed 100644
--- a/Source/core/platform/image-decoders/webp/WEBPImageDecoder.cpp
+++ b/Source/core/platform/image-decoders/webp/WEBPImageDecoder.cpp
@@ -172,7 +172,7 @@ void WEBPImageDecoder::readColorProfile(const uint8_t* data, size_t size)
WebPDemuxDelete(demuxer);
}
-void WEBPImageDecoder::applyColorProfile(const uint8_t* data, size_t size, ImageFrame& buffer)
+void WEBPImageDecoder::applyColorProfile(const uint8_t* data, size_t dataSize, ImageFrame& buffer)
{
int width;
int decodedHeight;
@@ -182,12 +182,12 @@ void WEBPImageDecoder::applyColorProfile(const uint8_t* data, size_t size, Image
return;
if (!m_haveReadProfile) {
- readColorProfile(data, size);
+ readColorProfile(data, dataSize);
m_haveReadProfile = true;
}
- ASSERT(width == scaledSize().width());
- ASSERT(decodedHeight <= scaledSize().height());
+ ASSERT(width == size().width());
+ ASSERT(decodedHeight <= size().height());
for (int y = m_decodedHeight; y < decodedHeight; ++y) {
uint8_t* row = reinterpret_cast<uint8_t*>(buffer.getAddr(0, y));
« no previous file with comments | « Source/core/platform/image-decoders/png/PNGImageDecoder.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698