OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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/damage_tracker.h" | 5 #include "cc/damage_tracker.h" |
6 | 6 |
7 #include "cc/layer_impl.h" | 7 #include "cc/layer_impl.h" |
8 #include "cc/layer_tree_host_common.h" | 8 #include "cc/layer_tree_host_common.h" |
9 #include "cc/math_util.h" | 9 #include "cc/math_util.h" |
10 #include "cc/render_surface_impl.h" | 10 #include "cc/render_surface_impl.h" |
11 #include <public/WebFilterOperations.h> | 11 #include "third_party/WebKit/Source/Platform/chromium/public/WebFilterOperations
.h" |
12 | 12 |
13 namespace cc { | 13 namespace cc { |
14 | 14 |
15 scoped_ptr<DamageTracker> DamageTracker::create() | 15 scoped_ptr<DamageTracker> DamageTracker::create() |
16 { | 16 { |
17 return make_scoped_ptr(new DamageTracker()); | 17 return make_scoped_ptr(new DamageTracker()); |
18 } | 18 } |
19 | 19 |
20 DamageTracker::DamageTracker() | 20 DamageTracker::DamageTracker() |
21 : m_forceFullDamageNextUpdate(false), | 21 : m_forceFullDamageNextUpdate(false), |
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
332 | 332 |
333 // If the layer has a background filter, this may cause pixels in our surfac
e to be expanded, so we will need to expand any damage | 333 // If the layer has a background filter, this may cause pixels in our surfac
e to be expanded, so we will need to expand any damage |
334 // at or below this layer. We expand the damage from this layer too, as we n
eed to readback those pixels from the surface with only | 334 // at or below this layer. We expand the damage from this layer too, as we n
eed to readback those pixels from the surface with only |
335 // the contents of layers below this one in them. This means we need to redr
aw any pixels in the surface being used for the blur in | 335 // the contents of layers below this one in them. This means we need to redr
aw any pixels in the surface being used for the blur in |
336 // this layer this frame. | 336 // this layer this frame. |
337 if (layer->backgroundFilters().hasFilterThatMovesPixels()) | 337 if (layer->backgroundFilters().hasFilterThatMovesPixels()) |
338 expandDamageRectInsideRectWithFilters(targetDamageRect, surfaceRectInTar
getSpace, layer->backgroundFilters()); | 338 expandDamageRectInsideRectWithFilters(targetDamageRect, surfaceRectInTar
getSpace, layer->backgroundFilters()); |
339 } | 339 } |
340 | 340 |
341 } // namespace cc | 341 } // namespace cc |
OLD | NEW |