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

Side by Side Diff: cc/output/filter_operation.cc

Issue 185653013: [#8] Pass gfx::Point by const ref. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed build errors on other platforms Created 6 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 unified diff | Download patch
« no previous file with comments | « cc/output/filter_operation.h ('k') | cc/output/gl_renderer.cc » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 <algorithm> 5 #include <algorithm>
6 6
7 #include "base/values.h" 7 #include "base/values.h"
8 #include "cc/base/math_util.h" 8 #include "cc/base/math_util.h"
9 #include "cc/output/filter_operation.h" 9 #include "cc/output/filter_operation.h"
10 #include "third_party/skia/include/core/SkMath.h" 10 #include "third_party/skia/include/core/SkMath.h"
(...skipping 22 matching lines...) Expand all
33 drop_shadow_offset_(0, 0), 33 drop_shadow_offset_(0, 0),
34 drop_shadow_color_(0), 34 drop_shadow_color_(0),
35 zoom_inset_(0) { 35 zoom_inset_(0) {
36 DCHECK_NE(type_, DROP_SHADOW); 36 DCHECK_NE(type_, DROP_SHADOW);
37 DCHECK_NE(type_, COLOR_MATRIX); 37 DCHECK_NE(type_, COLOR_MATRIX);
38 DCHECK_NE(type_, REFERENCE); 38 DCHECK_NE(type_, REFERENCE);
39 memset(matrix_, 0, sizeof(matrix_)); 39 memset(matrix_, 0, sizeof(matrix_));
40 } 40 }
41 41
42 FilterOperation::FilterOperation(FilterType type, 42 FilterOperation::FilterOperation(FilterType type,
43 gfx::Point offset, 43 const gfx::Point& offset,
44 float stdDeviation, 44 float stdDeviation,
45 SkColor color) 45 SkColor color)
46 : type_(type), 46 : type_(type),
47 amount_(stdDeviation), 47 amount_(stdDeviation),
48 drop_shadow_offset_(offset), 48 drop_shadow_offset_(offset),
49 drop_shadow_color_(color), 49 drop_shadow_color_(color),
50 zoom_inset_(0) { 50 zoom_inset_(0) {
51 DCHECK_EQ(type_, DROP_SHADOW); 51 DCHECK_EQ(type_, DROP_SHADOW);
52 memset(matrix_, 0, sizeof(matrix_)); 52 memset(matrix_, 0, sizeof(matrix_));
53 } 53 }
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 value->SetBoolean("is_null", !image_filter_); 260 value->SetBoolean("is_null", !image_filter_);
261 value->SetInteger("count_inputs", count_inputs); 261 value->SetInteger("count_inputs", count_inputs);
262 value->SetBoolean("can_filter_image_gpu", can_filter_image_gpu); 262 value->SetBoolean("can_filter_image_gpu", can_filter_image_gpu);
263 break; 263 break;
264 } 264 }
265 } 265 }
266 return value.PassAs<base::Value>(); 266 return value.PassAs<base::Value>();
267 } 267 }
268 268
269 } // namespace cc 269 } // namespace cc
OLDNEW
« no previous file with comments | « cc/output/filter_operation.h ('k') | cc/output/gl_renderer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698