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

Side by Side Diff: Source/core/paint/LayerClipRecorder.h

Issue 757183003: Revert of Enable fast/images with slimming paint (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years 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/HTMLCanvasPainter.cpp ('k') | Source/core/paint/LayerClipRecorder.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef LayerClipRecorder_h
6 #define LayerClipRecorder_h
7
8 #include "core/paint/ViewDisplayList.h"
9 #include "core/rendering/LayerPaintingInfo.h"
10 #include "core/rendering/PaintPhase.h"
11 #include "wtf/Vector.h"
12
13 namespace blink {
14
15 class ClipRect;
16 class GraphicsContext;
17 class RenderLayerModelObject;
18
19 class LayerClipRecorder {
20 public:
21
22 enum BorderRadiusClippingRule { IncludeSelfForBorderRadius, DoNotIncludeSelf ForBorderRadius };
23
24 // Set rounded clip rectangles defined by border radii all the way from the LayerPaintingInfo
25 // "root" layer down to the specified layer (or the parent of said layer, in case
26 // BorderRadiusClippingRule says to skip self). fragmentOffset is used for m ulticol, to specify
27 // the translation required to get from flow thread coordinates to visual co ordinates for a
28 // certain column.
29 // FIXME: The BorderRadiusClippingRule parameter is really useless now. If w e want to skip self,
30 // why not just supply the parent layer as the first parameter instead?
31 // FIXME: The ClipRect passed is in visual coordinates (not flow thread coor dinates), but at the
32 // same time we pass a fragmentOffset, so that we can translate from flow th read coordinates to
33 // visual coordinates. This may look rather confusing/redundant, but it is n eeded for rounded
34 // border clipping. Would be nice to clean up this.
35 explicit LayerClipRecorder(const RenderLayerModelObject*, GraphicsContext*, DisplayItem::Type, const ClipRect&, const LayerPaintingInfo* localPaintingInfo, const LayoutPoint& fragmentOffset, PaintLayerFlags, BorderRadiusClippingRule = I ncludeSelfForBorderRadius);
36
37 ~LayerClipRecorder();
38
39 private:
40
41 void collectRoundedRectClips(RenderLayer&, const LayerPaintingInfo& localPai ntingInfo, GraphicsContext*, const LayoutPoint& fragmentOffset, PaintLayerFlags,
42 BorderRadiusClippingRule, Vector<RoundedRect>& roundedRectClips);
43
44 GraphicsContext* m_graphicsContext;
45 const RenderLayerModelObject* m_renderer;
46 };
47
48 } // namespace blink
49
50 #endif // LayerDisplayList_h
OLDNEW
« no previous file with comments | « Source/core/paint/HTMLCanvasPainter.cpp ('k') | Source/core/paint/LayerClipRecorder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698