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

Unified Diff: skia/ext/image_operations_unittest.cc

Issue 6696085: Add the ability to write comments to PNGCodec::Encode. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: strdup Created 9 years, 9 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
Index: skia/ext/image_operations_unittest.cc
diff --git a/skia/ext/image_operations_unittest.cc b/skia/ext/image_operations_unittest.cc
index c1bd3e17872cd38a0f4e207f312e5ac5c5a77901..e8c0e9f3a8887abc67d9f83edd506b2e9dad60d0 100644
--- a/skia/ext/image_operations_unittest.cc
+++ b/skia/ext/image_operations_unittest.cc
@@ -14,6 +14,7 @@
#include "third_party/skia/include/core/SkBitmap.h"
#include "third_party/skia/include/core/SkRect.h"
#include "ui/gfx/codec/png_codec.h"
+#include "ui/gfx/size.h"
namespace {
@@ -193,9 +194,9 @@ void SaveBitmapToPNG(const SkBitmap& bmp, const char* path) {
gfx::PNGCodec::ColorFormat color_format = gfx::PNGCodec::FORMAT_RGBA;
if (!gfx::PNGCodec::Encode(
reinterpret_cast<const unsigned char*>(bmp.getPixels()),
- color_format, bmp.width(), bmp.height(),
+ color_format, gfx::Size(bmp.width(), bmp.height()),
static_cast<int>(bmp.rowBytes()),
- false, &png)) {
+ false, std::vector<gfx::PNGCodec::Comment>(), &png)) {
FAIL() << "Failed to encode image";
}

Powered by Google App Engine
This is Rietveld 408576698