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

Unified Diff: Source/core/platform/image-encoders/skia/PNGImageEncoder.cpp

Issue 54653004: Break dependency of platform/graphics on html/ImageData.h (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move struct into ImageBuffer.h Created 7 years, 1 month 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
Index: Source/core/platform/image-encoders/skia/PNGImageEncoder.cpp
diff --git a/Source/core/platform/image-encoders/skia/PNGImageEncoder.cpp b/Source/core/platform/image-encoders/skia/PNGImageEncoder.cpp
index edb1e46285fee236aa8bd3da48b26a62eeb4d3d3..8e8710c1ae36a4dbcff959c59005ed9a2c5df65a 100644
--- a/Source/core/platform/image-encoders/skia/PNGImageEncoder.cpp
+++ b/Source/core/platform/image-encoders/skia/PNGImageEncoder.cpp
@@ -34,7 +34,7 @@
#include "SkBitmap.h"
#include "SkColorPriv.h"
#include "SkUnPreMultiply.h"
-#include "core/html/ImageData.h"
+#include "core/platform/graphics/ImageBuffer.h"
#include "platform/geometry/IntSize.h"
extern "C" {
#include "png.h"
@@ -124,9 +124,9 @@ bool PNGImageEncoder::encode(const SkBitmap& bitmap, Vector<unsigned char>* outp
return encodePixels(IntSize(bitmap.width(), bitmap.height()), static_cast<unsigned char*>(bitmap.getPixels()), true, output);
}
-bool PNGImageEncoder::encode(const ImageData& imageData, Vector<unsigned char>* output)
+bool PNGImageEncoder::encode(const ImageDataBuffer& imageData, Vector<unsigned char>* output)
{
- return encodePixels(imageData.size(), imageData.data()->data(), false, output);
+ return encodePixels(imageData.size(), imageData.data(), false, output);
}
} // namespace WebCore

Powered by Google App Engine
This is Rietveld 408576698