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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/paint/README.md

Issue 2299533002: WIP: Construct SPV2's scroll paint property tree (Closed)
Patch Set: Add more paint property builder tests, update comments/documentation" Created 4 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
OLDNEW
1 # Platform paint code 1 # Platform paint code
2 2
3 This directory contains the implementation of display lists and display 3 This directory contains the implementation of display lists and display
4 list-based painting, except for code which requires knowledge of `core/` 4 list-based painting, except for code which requires knowledge of `core/`
5 concepts, such as DOM elements and layout objects. 5 concepts, such as DOM elements and layout objects.
6 6
7 This code is owned by the [paint team][paint-team-site]. 7 This code is owned by the [paint team][paint-team-site].
8 8
9 Slimming Paint v2 is currently being implemented. Unlike Slimming Paint v1, SPv2 9 Slimming Paint v2 is currently being implemented. Unlike Slimming Paint v1, SPv2
10 represents its paint artifact not as a flat display list, but as a list of 10 represents its paint artifact not as a flat display list, but as a list of
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 86
87 Each clip node has: 87 Each clip node has:
88 88
89 * A float rect with (optionally) rounded corner radius. 89 * A float rect with (optionally) rounded corner radius.
90 * An associated transform node, which the clip rect is based on. 90 * An associated transform node, which the clip rect is based on.
91 91
92 The raster region defined by a node is the rounded rect transformed to the 92 The raster region defined by a node is the rounded rect transformed to the
93 root space, intersects with the raster region defined by its parent clip node 93 root space, intersects with the raster region defined by its parent clip node
94 (if not root). 94 (if not root).
95 95
96 ### Scrolling
97
98 Each paint chunk is associated with a [scroll node](ScrollPaintPropertyNode.h)
99 which defines information about how a subtree scrolls so threads other than the
100 main thread can perform scrolling. Scroll information includes:
101
102 * Which directions, if any, are scrollable by the user.
103 * A reference to a [transform node](TransformPaintPropertyNode.h) which contains
104 a 2d scroll offset.
105 * The extent that can be scrolled. For example, an overflow clip of size 7x9
106 with scrolling contents of size 7x13 can scroll 4px vertically and none
107 horizontally.
108
109 To ensure geometry operations are simple and only deal with transforms, the
110 scroll offset is stored as a 2d transform in the transform tree.
111
96 ### Effects 112 ### Effects
97 113
98 Each paint chunk is associated with an [effect node](EffectPaintPropertyNode.h), 114 Each paint chunk is associated with an [effect node](EffectPaintPropertyNode.h),
99 which defines the effect (opacity, transfer mode, filter, mask, etc.) that 115 which defines the effect (opacity, transfer mode, filter, mask, etc.) that
100 should be applied to the content before or as it is composited into the content 116 should be applied to the content before or as it is composited into the content
101 below. 117 below.
102 118
103 Each effect node has: 119 Each effect node has:
104 120
105 * a floating-point opacity (from 0 to 1, inclusive) 121 * a floating-point opacity (from 0 to 1, inclusive)
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 visual and transformed rects of display items in the coordinate space of ancesto r 265 visual and transformed rects of display items in the coordinate space of ancesto r
250 [`PropertyTreeState`](PropertyTreeState.h)s. 266 [`PropertyTreeState`](PropertyTreeState.h)s.
251 267
252 The transformed rect of a display item in an ancestor `PropertyTreeState` is tha t 268 The transformed rect of a display item in an ancestor `PropertyTreeState` is tha t
253 rect, multiplied by the transforms between the display item's `PropertyTreeState ` 269 rect, multiplied by the transforms between the display item's `PropertyTreeState `
254 and the ancestors, then flattened into 2D. 270 and the ancestors, then flattened into 2D.
255 271
256 The visual rect of a display item in an ancestor `PropertyTreeState` is the inte rsection 272 The visual rect of a display item in an ancestor `PropertyTreeState` is the inte rsection
257 of all of the intermediate clips (transformed in to the ancestor state), with 273 of all of the intermediate clips (transformed in to the ancestor state), with
258 the display item's transformed rect. 274 the display item's transformed rect.
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698