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

Side by Side Diff: Source/core/paint/FilterPainter.cpp

Issue 1315303009: Cleanup DeprecatedPaintLayer::physicalBoundingBox() and derivatives (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 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 | « Source/core/paint/DeprecatedPaintLayerPainter.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "config.h" 5 #include "config.h"
6 #include "core/paint/FilterPainter.h" 6 #include "core/paint/FilterPainter.h"
7 7
8 #include "core/paint/DeprecatedPaintLayer.h" 8 #include "core/paint/DeprecatedPaintLayer.h"
9 #include "core/paint/FilterEffectBuilder.h" 9 #include "core/paint/FilterEffectBuilder.h"
10 #include "core/paint/LayerClipRecorder.h" 10 #include "core/paint/LayerClipRecorder.h"
(...skipping 22 matching lines...) Expand all
33 ASSERT(layer.filterInfo()); 33 ASSERT(layer.filterInfo());
34 34
35 SkiaImageFilterBuilder builder; 35 SkiaImageFilterBuilder builder;
36 RefPtrWillBeRawPtr<FilterEffect> lastEffect = layer.filterEffectBuilder()->l astEffect(); 36 RefPtrWillBeRawPtr<FilterEffect> lastEffect = layer.filterEffectBuilder()->l astEffect();
37 lastEffect->determineFilterPrimitiveSubregion(MapRectForward); 37 lastEffect->determineFilterPrimitiveSubregion(MapRectForward);
38 RefPtr<SkImageFilter> imageFilter = builder.build(lastEffect.get(), ColorSpa ceDeviceRGB); 38 RefPtr<SkImageFilter> imageFilter = builder.build(lastEffect.get(), ColorSpa ceDeviceRGB);
39 if (!imageFilter) 39 if (!imageFilter)
40 return; 40 return;
41 41
42 if (!rootRelativeBoundsComputed) { 42 if (!rootRelativeBoundsComputed) {
43 rootRelativeBounds = layer.physicalBoundingBoxIncludingReflectionAndStac kingChildren(paintingInfo.rootLayer, offsetFromRoot); 43 rootRelativeBounds = layer.physicalBoundingBoxIncludingReflectionAndStac kingChildren(offsetFromRoot);
44 rootRelativeBoundsComputed = true; 44 rootRelativeBoundsComputed = true;
45 } 45 }
46 46
47 // We'll handle clipping to the dirty rect before filter rasterization. 47 // We'll handle clipping to the dirty rect before filter rasterization.
48 // Filter processing will automatically expand the clip rect and the offscre en to accommodate any filter outsets. 48 // Filter processing will automatically expand the clip rect and the offscre en to accommodate any filter outsets.
49 // FIXME: It is incorrect to just clip to the damageRect here once multiple fragments are involved. 49 // FIXME: It is incorrect to just clip to the damageRect here once multiple fragments are involved.
50 50
51 // Subsequent code should not clip to the dirty rect, since we've already 51 // Subsequent code should not clip to the dirty rect, since we've already
52 // done it above, and doing it later will defeat the outsets. 52 // done it above, and doing it later will defeat the outsets.
53 paintingInfo.clipToDirtyRect = false; 53 paintingInfo.clipToDirtyRect = false;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 else 92 else
93 m_context->displayItemList()->createAndAppend<EndFilterDisplayIt em>(*m_layoutObject); 93 m_context->displayItemList()->createAndAppend<EndFilterDisplayIt em>(*m_layoutObject);
94 } 94 }
95 } else { 95 } else {
96 EndFilterDisplayItem endFilterDisplayItem(*m_layoutObject); 96 EndFilterDisplayItem endFilterDisplayItem(*m_layoutObject);
97 endFilterDisplayItem.replay(*m_context); 97 endFilterDisplayItem.replay(*m_context);
98 } 98 }
99 } 99 }
100 100
101 } // namespace blink 101 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/paint/DeprecatedPaintLayerPainter.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698