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

Side by Side Diff: cc/test/pixel_test_utils.cc

Issue 12965007: Fix cpplint errors in cc/(animation|input|layers|trees|test)/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 7 years, 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/test/pixel_test.cc ('k') | cc/test/render_pass_test_utils.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/test/pixel_test_utils.h" 5 #include "cc/test/pixel_test_utils.h"
6 6
7 #include <string>
8 #include <vector>
9
7 #include "base/file_util.h" 10 #include "base/file_util.h"
8 #include "base/logging.h" 11 #include "base/logging.h"
9 #include "third_party/skia/include/core/SkBitmap.h" 12 #include "third_party/skia/include/core/SkBitmap.h"
10 #include "ui/gfx/codec/png_codec.h" 13 #include "ui/gfx/codec/png_codec.h"
11 14
12 namespace cc { 15 namespace cc {
13 16
14 bool WritePNGFile(const SkBitmap& bitmap, const base::FilePath& file_path) { 17 bool WritePNGFile(const SkBitmap& bitmap, const base::FilePath& file_path) {
15 std::vector<unsigned char> png_data; 18 std::vector<unsigned char> png_data;
16 const bool discard_transparency = true; 19 const bool discard_transparency = true;
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 72
70 if (diff_pixels_count != 0) { 73 if (diff_pixels_count != 0) {
71 LOG(ERROR) << "Images differ by pixel count: " << diff_pixels_count; 74 LOG(ERROR) << "Images differ by pixel count: " << diff_pixels_count;
72 return false; 75 return false;
73 } 76 }
74 77
75 return true; 78 return true;
76 } 79 }
77 80
78 } // namespace cc 81 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/pixel_test.cc ('k') | cc/test/render_pass_test_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698