| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
R=danakj@chromium.org,enne@chromium.org
BUG=369757,368935
Review URL: https://codereview.chromium.org/266913021
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@269835 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch adds a flag that says whether the layer is currently in RSLL.
Used to remove layers that previously were in RSLL and are no longer
there.
R=enne, danakj
Review URL: https://codereview.chromium.org/265883013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@269353 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We can early-out in this function if we have a non-invertible, non-animated
transform. This causes us to not reset some dirty bits (in particular,
|sorted_for_recursion|). Later, when sorting a layer's child list (_before_
we decide to early-out of CalculateDrawProperties), we skip out on sorting
the layer due to the dirty state. This causes badness. We should reset the
state and sort the list properly, including the layers that will be skipped
later.
R=vollick@chromium.org,ajuma@chromium.org,danakj@chromium.org
BUG=366233
Review URL: https://codereview.chromium.org/267713011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268026 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Plumb a flag through from telemetry tests to the layer
painting code that disables the WebCore::GraphicsContext.
This allows us to isolate the various systems that paint
web content in Chromium.
R=nduca@chromium.org,skyostil@chromium.org
BUG=350684
Review URL: https://codereview.chromium.org/253013003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267913 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, we bail early in this function if we encounter a layer with
a singular transform. This causes problems because we depend on a full
tree walk in order to clear DrawProperties::sorted_for_recursion. This
cl prevents this early out.
(Note: this does not affect other optimizations to prevent the drawing
of subtrees rooted at layers with singular transforms.)
R=ajuma@chromium.org,danakj@chromium.org
BUG=366233
Review URL: https://codereview.chromium.org/263643007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267438 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As an optimization, we used to clear render surfaces when they were
elided from the RenderSurfaceLayerList. It turns out that these surfaces
are still important from time to time; a scroll child will need to
access the transforms of these surfaces in order to put its clip in the
right space.
This CL retains the layer lists and it also updates RenderSurface to
own a LayerList rather than a RenderSurfaceLayerList (which was always
a bit of a kludge).
R=danakj@chromium.org
BUG=366386
Review URL: https://codereview.chromium.org/250803013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266519 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CC touch hit testing now (as of http://crrev.com/264395 does a ray cast
through all layers under the touched point. We included an optimization
to stop searching once you reach a layer we know is opaque to hit testing.
This breaks the common case of sites with a touch handler on the document
because blink has an optimization to effectively disable touch hit testing
in that scenario (since there's no benefit to be had to expensive rect
computation) by marking just the entire root layer with a handler region.
This change removes this opaque-to-hit-testing optimization. There's some
risk that we'll block on main more often, but it should be rare (you'd
need a scrolling layer without a handler over top of a layer with a
handler).
This also fixes the case where a layer has a region that is supposed to
be transparent to hit-testing with the CSS pointer-events: none property.
BUG=366034, 269598
Review URL: https://codereview.chromium.org/250663003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266402 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In order to safeguard against transparent occluders, in
this CL, I've raycasted until I hit a layer that's
"opaque for hit testing" and if any layer I encounter
has a touch hit region that contains the given point,
I punt to main.
Note: depends on https://codereview.chromium.org/238803005/
BUG=351723
Review URL: https://codereview.chromium.org/239453009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264395 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
According to the CSS spec, if the transform of an object is
non-invertible the object and its content do not get displayed.
+ Added transform_is_invertible to Layer and LayerImpl which gets
calculated once when the transform is set. When pusing to another layer
the transform invertibility isn't recalculated.
+ Added invertibility check to LTHC::SubtreeShouldBeSkipped.
BUG=173726
Review URL: https://codereview.chromium.org/217313003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264341 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This re-rasterizes CPU-rasterized layers animating scale at the
maximum scale that will be applied during the animation, if this
maximum scale can be computed.
BUG=224913
Review URL: https://codereview.chromium.org/226283004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262737 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, any scaling in LTHI::external_transform_ is
ignored by PictureLayerImpl when deciding to create
tilings at different scales. If the scaling in external
transform is not 1, then the scaling will just be done
at draw time without creating new tilings at the new
scale.
This CL takes out the scale from external transform and
apply it to the device scale. This way PictureLayerImpl
will notice the scale change and create new tilings as
necessary.
This does mean device scale can change each frame and lead
to creating a lot of unnecessary tilings. However there
is no good signal to know whether a the transform is part
of an animation. So there is no good point like "animation
end" to update tiling.
BUG=357441
Review URL: https://codereview.chromium.org/227153011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262571 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The effective scroll delta is corrected for rounding to nearest screen
pixel, but this was done in the wrong coordinate space (scroll delta is
in CSS pixels, not physical pixels).
NOTRY=true
BUG=357889
Review URL: https://codereview.chromium.org/216973006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261057 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
BUG=313494
Review URL: https://codereview.chromium.org/191453002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@259160 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
This matches the behavior of the browser and renderer better, and lets us use SharedBitmaps in more tests.
Review URL: https://codereview.chromium.org/202763002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@258318 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes UpdateLayerContentsScale(Layer* layer, ...) so that if
the layer's content bounds or contents scale are changed, then its
needs_push_properties() flag is set.
BUG=345267
Review URL: https://codereview.chromium.org/178303002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253140 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We don't use it in blink. Let's get rid of it in cc, too.
Note: depends on https://codereview.chromium.org/78233009/.
R=enne@chromium.org
BUG=None
Review URL: https://codereview.chromium.org/167753002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@251621 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Preserve3d has implications for both sorting and flattening of
transforms. This is a bummer. Sometimes we want to allow a transform to
remain unflattened, but we don't want that to affect 3d sorting. With
this CL, we will have the ability to do that.
Note: this is essentially this cl
https://codereview.chromium.org/100393005/
..minus the generalizations to sorting that were being attempted in that
patch.
Note, this CL is gated on https://codereview.chromium.org/98373011/
R=enne@chromium.org
BUG=338980
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=249974
Review URL: https://codereview.chromium.org/147833003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@250474 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://codereview.chromium.org/147833003/)
Reason for revert:
Introduces flakiness in Blink layout tests:
http://test-results.appspot.com/dashboards/flakiness_dashboard.html#group=%2540ToT%2520Blink&tests=compositing%252Fbackface-visibility-transformed
Original issue's description:
> Split preserve3d into: "should-flatten" and "is-3d-sorted"
>
> Preserve3d has implications for both sorting and flattening of
> transforms. This is a bummer. Sometimes we want to allow a transform to
> remain unflattened, but we don't want that to affect 3d sorting. With
> this CL, we will have the ability to do that.
>
> Note: this is essentially this cl
> https://codereview.chromium.org/100393005/
>
> ..minus the generalizations to sorting that were being attempted in that
> patch.
>
> Note, this CL is gated on https://codereview.chromium.org/98373011/
>
> R=enne@chromium.org
> BUG=338980
>
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=249974
TBR=enne@chromium.org,shawnsingh@chromium.org,vollick@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=338980
Review URL: https://codereview.chromium.org/158563003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@250031 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Preserve3d has implications for both sorting and flattening of
transforms. This is a bummer. Sometimes we want to allow a transform to
remain unflattened, but we don't want that to affect 3d sorting. With
this CL, we will have the ability to do that.
Note: this is essentially this cl
https://codereview.chromium.org/100393005/
..minus the generalizations to sorting that were being attempted in that
patch.
Note, this CL is gated on https://codereview.chromium.org/98373011/
R=enne@chromium.org
BUG=338980
Review URL: https://codereview.chromium.org/147833003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249974 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
In LayerTreeHostCommon, when computing the drawing properties, a layer was being treated as visible if it was hidden and had copy requests. The intention is for the layer+subtree to be drawn as if the target layer were visible, just for read-back. However, a distinction must be made between whether a layer is "visible" versus "hidden, but still drawn." This is important when setting the render surface's contributes_to_drawn_surface property. If a layer is hidden, it does *not* contribute, regardless of whether it is drawn.
BUG=341318
TEST=New cc_unittests that fail before this change: LayerTreeHostReadbackPixelTest.ReadbackHiddenSubtree_* Confirmed LayerTreeHostCommonTest.SubtreeHidden*, and all other cc_unittests still pass.
Review URL: https://codereview.chromium.org/142443009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249627 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This CL supplies the necessary changes to CC to support the
inner/outer viewport model for pinch-zoom and fixed-position
elements. The specification for these changes is contained in
the document "Layer-based Solution for Pinch Zoom / Fixed
Position".
It incorporates a change to how scrollbar parameters are
computed (removes the notion of max_scroll_offset as a
quantity set be the embedder, and instead inferred from the
relative sizes of a clip layer w.r.t. the scroll layer).
Scrollbars are generalized so that a layer may have more than
two scrollbars, and the parameters of the scrollbar are set
w.r.t. the sizes and positions of a clip and a scroll layer.
Further, changes to the scrip/scroll layer automatically
notify any attached scrollbars.
The CL also removes existing references to root_scroll_layer
from LTH, LTI and LTHI and replaces them with either
Inner/OuterViewportScrollLayer (dual-layer operation only
exists at present if the --enable-pinch-virtual-viewport flag
is specified, otherwise behavior is unchanged).
Logic is added to (i) combine scroll offsets for the two
viewports before passing it to the embedder, and (ii)
splitting any offsets received from the embedder
appropriately between the two viewports.
This CL relies on https://codereview.chromium.org/138453004/
for changes in Blink to support it.
BUG=148816
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=246812
R=aelias@chromium.org, enne@chromium.org, joi@chromium.org, piman@chromium.org, sky@chromium.org
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=247684
Review URL: https://codereview.chromium.org/23983047
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@248092 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Any struct of size > 4 bytes should be passed by const ref.
Passing by ref for these structs is faster than passing by value,
especially when invoking function has multiple parameters and some
other scenarios mentioned in the bug.
BUG=159273
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=247426
Review URL: https://codereview.chromium.org/145313006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247769 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://codereview.chromium.org/23983047/)
Reason for revert:
Broke Linux ASAN Tests (3) bot.
Original issue's description:
> Pinch/Zoom Infrastructure & Plumbing CL
>
> This CL supplies the necessary changes to CC to support the
> inner/outer viewport model for pinch-zoom and fixed-position
> elements. The specification for these changes is contained in
> the document "Layer-based Solution for Pinch Zoom / Fixed
> Position".
>
> It incorporates a change to how scrollbar parameters are
> computed (removes the notion of max_scroll_offset as a
> quantity set be the embedder, and instead inferred from the
> relative sizes of a clip layer w.r.t. the scroll layer).
>
> Scrollbars are generalized so that a layer may have more than
> two scrollbars, and the parameters of the scrollbar are set
> w.r.t. the sizes and positions of a clip and a scroll layer.
> Further, changes to the scrip/scroll layer automatically
> notify any attached scrollbars.
>
> The CL also removes existing references to root_scroll_layer
> from LTH, LTI and LTHI and replaces them with either
> Inner/OuterViewportScrollLayer (dual-layer operation only
> exists at present if the --enable-pinch-virtual-viewport flag
> is specified, otherwise behavior is unchanged).
>
> Logic is added to (i) combine scroll offsets for the two
> viewports before passing it to the embedder, and (ii)
> splitting any offsets received from the embedder
> appropriately between the two viewports.
>
> This CL relies on https://codereview.chromium.org/138453004/
> for changes in Blink to support it.
>
> BUG=148816
>
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=246812
>
> R=aelias@chromium.org, enne@chromium.org, joi@chromium.org, piman@chromium.org, sky@chromium.org
>
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=247684
TBR=enne@chromium.org,aelias@chromium.org,joi@chromium.org,sky@chromium.org,piman@chromium.org,tony@chromium.org,wjmaclean@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=148816
Review URL: https://codereview.chromium.org/135183016
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247688 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This CL supplies the necessary changes to CC to support the
inner/outer viewport model for pinch-zoom and fixed-position
elements. The specification for these changes is contained in
the document "Layer-based Solution for Pinch Zoom / Fixed
Position".
It incorporates a change to how scrollbar parameters are
computed (removes the notion of max_scroll_offset as a
quantity set be the embedder, and instead inferred from the
relative sizes of a clip layer w.r.t. the scroll layer).
Scrollbars are generalized so that a layer may have more than
two scrollbars, and the parameters of the scrollbar are set
w.r.t. the sizes and positions of a clip and a scroll layer.
Further, changes to the scrip/scroll layer automatically
notify any attached scrollbars.
The CL also removes existing references to root_scroll_layer
from LTH, LTI and LTHI and replaces them with either
Inner/OuterViewportScrollLayer (dual-layer operation only
exists at present if the --enable-pinch-virtual-viewport flag
is specified, otherwise behavior is unchanged).
Logic is added to (i) combine scroll offsets for the two
viewports before passing it to the embedder, and (ii)
splitting any offsets received from the embedder
appropriately between the two viewports.
This CL relies on https://codereview.chromium.org/138453004/
for changes in Blink to support it.
BUG=148816
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=246812
R=aelias@chromium.org, enne@chromium.org, joi@chromium.org, piman@chromium.org, sky@chromium.org
Review URL: https://codereview.chromium.org/23983047
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247684 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://codereview.chromium.org/145313006/)
Reason for revert:
Suspected of breaking the Linux ASAN tests ( http://build.chromium.org/p/chromium.memory/builders/Linux%20ASAN%20Tests%20%283%29/builds/22104 )
Original issue's description:
> [#7] Pass gfx::Size by const ref.
>
> Any struct of size > 4 bytes should be passed by const ref.
> Passing by ref for these structs is faster than passing by value,
> especially when invoking function has multiple parameters and some
> other scenarios mentioned in the bug.
>
> BUG=159273
>
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=247426
TBR=danakj@chromium.org,enne@chromium.org,bulach@chromium.org,piman@chromium.org,prashant.n@samsung.com
NOTREECHECKS=true
NOTRY=true
BUG=159273
Review URL: https://codereview.chromium.org/142863008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247437 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Any struct of size > 4 bytes should be passed by const ref.
Passing by ref for these structs is faster than passing by value,
especially when invoking function has multiple parameters and some
other scenarios mentioned in the bug.
BUG=159273
Review URL: https://codereview.chromium.org/145313006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247426 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://codereview.chromium.org/23983047/)
Reason for revert:
This patch broke several blink-side compositing/rtl tests[1][2]. It's
unclear whether these tests are valuable, given some comments
in TestExpectations, but since I know nothing about compositing
I'll leave the decision about what to do with these tests up to
someone who does.
[1]: http://test-results.appspot.com/dashboards/flakiness_dashboard.html#group=%40ToT%20Blink&tests=compositing/rtl/rtl-iframe-absolute-overflow-scrolled.html,compositing/rtl/rtl-iframe-absolute-overflow.html,compositing/rtl/rtl-iframe-fixed-overflow-scrolled.html,compositing/rtl/rtl-iframe-fixed-overflow.html
[2]: http://build.chromium.org/p/chromium.webkit/builders/WebKit%20Mac10.7/builds/22131
Original issue's description:
> Pinch/Zoom Infrastructure & Plumbing CL
>
> This CL supplies the necessary changes to CC to support the
> inner/outer viewport model for pinch-zoom and fixed-position
> elements. The specification for these changes is contained in
> the document "Layer-based Solution for Pinch Zoom / Fixed
> Position".
>
> It incorporates a change to how scrollbar parameters are
> computed (removes the notion of max_scroll_offset as a
> quantity set be the embedder, and instead inferred from the
> relative sizes of a clip layer w.r.t. the scroll layer).
>
> Scrollbars are generalized so that a layer may have more than
> two scrollbars, and the parameters of the scrollbar are set
> w.r.t. the sizes and positions of a clip and a scroll layer.
> Further, changes to the scrip/scroll layer automatically
> notify any attached scrollbars.
>
> The CL also removes existing references to root_scroll_layer
> from LTH, LTI and LTHI and replaces them with either
> Inner/OuterViewportScrollLayer (dual-layer operation only
> exists at present if the --enable-pinch-virtual-viewport flag
> is specified, otherwise behavior is unchanged).
>
> Logic is added to (i) combine scroll offsets for the two
> viewports before passing it to the embedder, and (ii)
> splitting any offsets received from the embedder
> appropriately between the two viewports.
>
> This CL relies on https://codereview.chromium.org/138453004/
> for changes in Blink to support it.
>
> BUG=148816
>
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=246812
TBR=enne@chromium.org,aelias@chromium.org,joi@chromium.org,sky@chromium.org,piman@chromium.org,tony@chromium.org,wjmaclean@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=148816
Review URL: https://codereview.chromium.org/146713002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@246842 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This CL supplies the necessary changes to CC to support the
inner/outer viewport model for pinch-zoom and fixed-position
elements. The specification for these changes is contained in
the document "Layer-based Solution for Pinch Zoom / Fixed
Position".
It incorporates a change to how scrollbar parameters are
computed (removes the notion of max_scroll_offset as a
quantity set be the embedder, and instead inferred from the
relative sizes of a clip layer w.r.t. the scroll layer).
Scrollbars are generalized so that a layer may have more than
two scrollbars, and the parameters of the scrollbar are set
w.r.t. the sizes and positions of a clip and a scroll layer.
Further, changes to the scrip/scroll layer automatically
notify any attached scrollbars.
The CL also removes existing references to root_scroll_layer
from LTH, LTI and LTHI and replaces them with either
Inner/OuterViewportScrollLayer (dual-layer operation only
exists at present if the --enable-pinch-virtual-viewport flag
is specified, otherwise behavior is unchanged).
Logic is added to (i) combine scroll offsets for the two
viewports before passing it to the embedder, and (ii)
splitting any offsets received from the embedder
appropriately between the two viewports.
This CL relies on https://codereview.chromium.org/138453004/
for changes in Blink to support it.
BUG=148816
Review URL: https://codereview.chromium.org/23983047
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@246812 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Avoid unneccessary copy of structures gfx::PointF
by passing them by const ref rather than value.
Any struct of size > 4 bytes should be passed by const ref.
Passing by ref for these structs is faster than passing
by value, especially when invoking function has multiple parameters.
Pass by value creates unneccessary overhead which should be avoided.
BUG=159273
R=danakj, enne, piman
Review URL: https://codereview.chromium.org/139233002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@245467 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Avoid unneccessary copy of structures gfx::Rect & gfx::RectF
by passing them by const ref rather than value.
Any struct of size > 4 bytes should be passed by const ref.
Passing by ref for these structs is faster than passing
by value, especially when invoking function has multiple parameters.
Pass by value creates unneccessary overhead which should be avoided.
BUG=159273
Review URL: https://codereview.chromium.org/93663004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@244224 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reverting because this broke scrolling on mobile GMail.
> cc: Fix hit-testing in zero-opacity layers.
>
> If a layer that accepts touch or wheel events, but the layer (or one of its
> ancestor layers) has zero opacity, then make sure the layer hit-tests correctly.
>
> BUG=295295
> R=enne@chromium.org, rbyers@google.com
>
> Review URL: https://codereview.chromium.org/26112002
TBR=sadrul@chromium.org
BUG=318088,313523
Review URL: https://codereview.chromium.org/68933008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@234482 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a layer that accepts touch or wheel events, but the layer (or one of its
ancestor layers) has zero opacity, then make sure the layer hit-tests correctly.
BUG=295295
R=enne@chromium.org, rbyers@google.com
Review URL: https://codereview.chromium.org/26112002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@232881 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Scroll layers are snapped to integer coordinates, but fixed position
layers that compensated for that scroll weren't taking that into
consideration.
R=danakj@chromium.org
BUG=309179
Review URL: https://codereview.chromium.org/41603002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@230988 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a touch-layer is below a non-touch layer, and the two layers overlap,
then the overlapped region should not be treated as a touch-handling region.
This change updates FindLayerThatIsHitByPointInTouchHandlerRegion() to do the
right thing (which is currently used only in tests), and uses this function from
LayerTreeHostImpl::HaveTouchEventHandlersAt() (instead of having its own code).
BUG=none
R=enne@chromium.org
Review URL: https://codereview.chromium.org/27718006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@230578 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, I'd constructed temporary layer lists to hold the layer list
contributions from children when I visited them out of order in CalcDrawProps.
Unfortunately ~RenderSurfaceLayerList frees all the surfaces, so when the
temporary lists were destroyed, the surfaces would be nuked. To work around
this, I don't pass temporary lists to children, I just sort the "real" lists
after the recursion. When doing this sorting I allocate a LayerList for
Layers and a LayerImplList for LayerImpls. The types got a bit unwieldy when
doing this, so I also put some handy typedefs in Layer and LayerImpl. This lets
us cut down on the number of template parameters we use in LTHC.
TEST=LayerTreeHostCommonTest.OutOfOrderClippingRequiresRSLLSorting
R=danakj@chromium.org
BUG=309381
Review URL: https://codereview.chromium.org/29653002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@229619 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CalculateDrawPropertiesInternal when there are no scroll parents.""
This reverts commit 97ada322de9f492e3f0d1741ac117fc42599451b.
This was a speculative perf revert; seems not to be the issue. Relanding.
Local tests with and without this patch on a Nexus 4 with and without my patch didn't show a perf regression (in fact, perf seemed to mysteriously improve -- I assume this is noise).
TBR=danakj@chromium.org
BUG=306926
Review URL: https://codereview.chromium.org/26135005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@229221 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CalculateDrawPropertiesInternal when there are no scroll parents."
Speculative revert to see if this affects SVG perf.
This reverts commit 7d148876b818e079b85821b702dd9dbe592127f5.
Conflicts:
cc/trees/layer_tree_host_common.cc
Revert "Improve perf of CalculateDrawPropertiesInternal when there are no scroll parents."
This reverts commit 1cdf6668b7665cbc984d1f7eb75548ec4b8af3b0.
TBR=vollick@chromium.org
BUG=306926
Review URL: https://codereview.chromium.org/27341002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@228678 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, we had required that we inherit our clip from our direct ancestor or
our clip parent (which has to be an ancestor). This CL loosens that restriction
and allows clipping by our scroll parent, which will not be our ancestor.
In order for this to work, we must ensure that the scroll parent's clip is
computed before we compute the clip children's. This is accomplished by changing
the order in which we recur through the layer tree and sorting layer lists
afterward to ensure that we ultimately stack correctly.
NB: I have taken care to only sort the newly added layers, and to only sort when
the child order has actually changed, which should happen rarely.
Tests:
1. LayerTreeHostCommonTest.ClippedByScrollParent
- Checks that the simple case (where the scroll parent is naturally processed
before the scroll child) results in the correct clips.
2. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollParent
- Identical to (1) but checks that clips are still correct when the scroll
parent needs to be visited out of order.
3. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollGrandparent
- Similar to (2), but also checks that clips are set up correctly if the
scroll parent has yet another scroll parent (sorting for recursion is a bit
tougher in this case).
- Also checks that despite visiting layers out of order, that the layer list
ends up in paint order.
4. LayerTreeHostCommonTest.OutOfOrderClippingRequiresRSLLSorting
- Similar to (3), but includes several render surfaces in the tree and checks
that the resulting render surface layer list is ordered correctly.
5. LayerTreeHostCommonTest.DoNotClobberSorting
- Ensures that if we have to reorder layer list contributions that we do not break 3d sorting.
BUG=291413
R=danakj@chromium.org, enne@chromium.org, hartmanng@chromium.org
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=225858
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=226219
Review URL: https://codereview.chromium.org/23536049
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@227519 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There is a precision lost issue for texture layers with CSS
transforms(Scaling) when applying TextureDrawQuad::PerformClipping()
to avoid explicitly setting a scissor. The rect is first divided by
the scale_factor, then round to integer value and finally multiplied
by the scale_factor in GLRenderer::EnqueueTextureQuad(). The round
process loses precision and the later scale operation enlarges the
error. This error leads to wrong width and height drawn and
introduces visual defects.
BUG=240259
Review URL: https://codereview.chromium.org/24427006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@227177 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The RenderSurfaceLayerList is supposed to contain any layers which are visible
or that are eligible for hit testing. This change ensures that empty layers
(those with drawsContent=false) are left in the RSSL when they have touch or
wheel handlers, so that we can find them in hit testing.
BUG=289766
R=danakj@chromium.org
Review URL: https://codereview.chromium.org/25712004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@227164 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Likely broke unit tests on Android:
http://build.chromium.org/p/chromium.linux/builders/Android%20Tests/builds/8345
> Allow clipping by scroll parents.
>
> Previously, we had required that we inherit our clip from our direct ancestor or
> our clip parent (which has to be an ancestor). This CL loosens that restriction
> and allows clipping by our scroll parent, which will not be our ancestor.
>
> In order for this to work, we must ensure that the scroll parent's clip is
> computed before we compute the clip children's. This is accomplished by changing
> the order in which we recur through the layer tree and sorting layer lists
> afterward to ensure that we ultimately stack correctly.
>
> NB: I have taken care to only sort the newly added layers, and to only sort when
> the child order has actually changed, which should happen rarely.
>
> Tests:
> 1. LayerTreeHostCommonTest.ClippedByScrollParent
> - Checks that the simple case (where the scroll parent is naturally processed
> before the scroll child) results in the correct clips.
> 2. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollParent
> - Identical to (1) but checks that clips are still correct when the scroll
> parent needs to be visited out of order.
> 3. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollGrandparent
> - Similar to (2), but also checks that clips are set up correctly if the
> scroll parent has yet another scroll parent (sorting for recursion is a bit
> tougher in this case).
> - Also checks that despite visiting layers out of order, that the layer list
> ends up in paint order.
> 4. LayerTreeHostCommonTest.OutOfOrderClippingRequiresRSLLSorting
> - Similar to (3), but includes several render surfaces in the tree and checks
> that the resulting render surface layer list is ordered correctly.
> 5. LayerTreeHostCommonTest.DoNotClobberSorting
> - Ensures that if we have to reorder layer list contributions that we do not break 3d sorting.
>
> BUG=291413
> R=danakj@chromium.org, enne@chromium.org, hartmanng@chromium.org
>
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=225858
>
> Review URL: https://codereview.chromium.org/23536049
TBR=vollick@chromium.org
Review URL: https://codereview.chromium.org/25542002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@226231 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, we had required that we inherit our clip from our direct ancestor or
our clip parent (which has to be an ancestor). This CL loosens that restriction
and allows clipping by our scroll parent, which will not be our ancestor.
In order for this to work, we must ensure that the scroll parent's clip is
computed before we compute the clip children's. This is accomplished by changing
the order in which we recur through the layer tree and sorting layer lists
afterward to ensure that we ultimately stack correctly.
NB: I have taken care to only sort the newly added layers, and to only sort when
the child order has actually changed, which should happen rarely.
Tests:
1. LayerTreeHostCommonTest.ClippedByScrollParent
- Checks that the simple case (where the scroll parent is naturally processed
before the scroll child) results in the correct clips.
2. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollParent
- Identical to (1) but checks that clips are still correct when the scroll
parent needs to be visited out of order.
3. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollGrandparent
- Similar to (2), but also checks that clips are set up correctly if the
scroll parent has yet another scroll parent (sorting for recursion is a bit
tougher in this case).
- Also checks that despite visiting layers out of order, that the layer list
ends up in paint order.
4. LayerTreeHostCommonTest.OutOfOrderClippingRequiresRSLLSorting
- Similar to (3), but includes several render surfaces in the tree and checks
that the resulting render surface layer list is ordered correctly.
5. LayerTreeHostCommonTest.DoNotClobberSorting
- Ensures that if we have to reorder layer list contributions that we do not break 3d sorting.
BUG=291413
R=danakj@chromium.org, enne@chromium.org, hartmanng@chromium.org
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=225858
Review URL: https://codereview.chromium.org/23536049
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@226219 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
> Allow clipping by scroll parents.
>
> Previously, we had required that we inherit our clip from our direct ancestor or
> our clip parent (which has to be an ancestor). This CL loosens that restriction
> and allows clipping by our scroll parent, which will not be our ancestor.
>
> In order for this to work, we must ensure that the scroll parent's clip is
> computed before we compute the clip children's. This is accomplished by changing
> the order in which we recur through the layer tree and sorting layer lists
> afterward to ensure that we ultimately stack correctly.
>
> NB: I have taken care to only sort the newly added layers, and to only sort when
> the child order has actually changed, which should happen rarely.
>
> Tests:
> 1. LayerTreeHostCommonTest.ClippedByScrollParent
> - Checks that the simple case (where the scroll parent is naturally processed
> before the scroll child) results in the correct clips.
> 2. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollParent
> - Identical to (1) but checks that clips are still correct when the scroll
> parent needs to be visited out of order.
> 3. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollGrandparent
> - Similar to (2), but also checks that clips are set up correctly if the
> scroll parent has yet another scroll parent (sorting for recursion is a bit
> tougher in this case).
> - Also checks that despite visiting layers out of order, that the layer list
> ends up in paint order.
> 4. LayerTreeHostCommonTest.OutOfOrderClippingRequiresRSLLSorting
> - Similar to (3), but includes several render surfaces in the tree and checks
> that the resulting render surface layer list is ordered correctly.
> 5. LayerTreeHostCommonTest.DoNotClobberSorting
> - Ensures that if we have to reorder layer list contributions that we do not break 3d sorting.
>
> BUG=291413
> R=danakj@chromium.org, enne@chromium.org, hartmanng@chromium.org
>
> Review URL: https://codereview.chromium.org/23536049
TBR=vollick@chromium.org
Review URL: https://codereview.chromium.org/25058006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@225860 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, we had required that we inherit our clip from our direct ancestor or
our clip parent (which has to be an ancestor). This CL loosens that restriction
and allows clipping by our scroll parent, which will not be our ancestor.
In order for this to work, we must ensure that the scroll parent's clip is
computed before we compute the clip children's. This is accomplished by changing
the order in which we recur through the layer tree and sorting layer lists
afterward to ensure that we ultimately stack correctly.
NB: I have taken care to only sort the newly added layers, and to only sort when
the child order has actually changed, which should happen rarely.
Tests:
1. LayerTreeHostCommonTest.ClippedByScrollParent
- Checks that the simple case (where the scroll parent is naturally processed
before the scroll child) results in the correct clips.
2. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollParent
- Identical to (1) but checks that clips are still correct when the scroll
parent needs to be visited out of order.
3. LayerTreeHostCommonTest.ClippedByOutOfOrderScrollGrandparent
- Similar to (2), but also checks that clips are set up correctly if the
scroll parent has yet another scroll parent (sorting for recursion is a bit
tougher in this case).
- Also checks that despite visiting layers out of order, that the layer list
ends up in paint order.
4. LayerTreeHostCommonTest.OutOfOrderClippingRequiresRSLLSorting
- Similar to (3), but includes several render surfaces in the tree and checks
that the resulting render surface layer list is ordered correctly.
5. LayerTreeHostCommonTest.DoNotClobberSorting
- Ensures that if we have to reorder layer list contributions that we do not break 3d sorting.
BUG=291413
R=danakj@chromium.org, enne@chromium.org, hartmanng@chromium.org
Review URL: https://codereview.chromium.org/23536049
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@225858 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently when DrawProperties decides a subtree needs a render surface,
Android WebView software mode just drops it at CalculateRenderPasses
time and draws nothing. If we instead suppress the render surface
decision at an earlier stage, we're more likely to get a halfway
reasonable result.
The motivating example was a page setting preserve-3d where the render
surface didn't affect the output result anyway.
New test LayerTreeHostCommonTest.CanRenderToSeparateSurface.
NOTRY=true
BUG=297299
Review URL: https://codereview.chromium.org/24280009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@225637 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change also cleans up the use of gfx::Transform::get/setDouble
(in favor of get/set) at callsites to prepare for changing SkMScalar
from double to float.
BUG=269817
Originally Committed/Reverted: https://src.chromium.org/viewvc/chrome?view=rev&revision=224725
Review URL: https://chromiumcodereview.appspot.com/23811009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@225130 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reverting as caused perf regression because of new static
initializers.
> Fix compilation and ui_unittests with float transforms
>
> This change also cleans up the use of gfx::Transform::get/setDouble
> (in favor of get/set) at callsites to prepare for changing SkMScalar
> from double to float.
>
> BUG=269817
>
> Review URL: https://chromiumcodereview.appspot.com/23811009
TBR=enne@chromium.org
Review URL: https://codereview.chromium.org/23537065
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@224732 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change also cleans up the use of gfx::Transform::get/setDouble
(in favor of get/set) at callsites to prepare for changing SkMScalar
from double to float.
BUG=269817
Review URL: https://chromiumcodereview.appspot.com/23811009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@224725 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
BUG=269819
Review URL: https://chromiumcodereview.appspot.com/23043011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@222683 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If we don't clear the layer's render surface when we early out, we'll build the
render surface layer list incorrectly, and the layer iterator will crash trying
to iterate over it. I've done this at the first early out, but I missed this
at the second.
R=danakj@chromium.org
BUG=280613
Review URL: https://chromiumcodereview.appspot.com/23708003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@220194 0039d316-1c4b-4281-b951-d872f2087c98
|