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

Issue 15139007: Ensure LayerTreeHostImpl's current frame time is updated every frame (Closed)

Created:
7 years, 7 months ago by ajuma
Modified:
7 years, 7 months ago
Reviewers:
danakj, brianderson
CC:
chromium-reviews, cc-bugs_chromium.org, Ian Vollick, brianderson
Visibility:
Public.

Description

Ensure LayerTreeHostImpl's current frame time is updated every frame LayerTreeHostImpl's current frame time is currently updated after every draw. This means that if, in some frame, we try (and fail) to activate the pending tree but we don't draw, then when we eventually do draw we'll be using an old current frame time. As a result, animations started during that frame will have an old start time, and hence will appear to jump during the following frame. This CL makes us update the current frame time after every frame, regardless of whether drawing occurred during the frame. BUG=240820 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=200920

Patch Set 1 #

Total comments: 2

Patch Set 2 : Address review comments #

Total comments: 7

Patch Set 3 : #

Patch Set 4 : Fix Windows flake #

Patch Set 5 : #

Total comments: 5

Patch Set 6 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+110 lines, -10 lines) Patch
M cc/test/layer_tree_test.h View 1 chunk +1 line, -1 line 0 comments Download
M cc/test/layer_tree_test.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M cc/trees/layer_tree_host_impl.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M cc/trees/layer_tree_host_impl.cc View 1 2 2 chunks +2 lines, -2 lines 0 comments Download
M cc/trees/layer_tree_host_unittest.cc View 1 2 3 4 5 1 chunk +101 lines, -0 lines 0 comments Download
M cc/trees/layer_tree_host_unittest_scroll.cc View 1 chunk +1 line, -1 line 0 comments Download
M cc/trees/single_thread_proxy.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M cc/trees/thread_proxy.cc View 1 2 2 chunks +1 line, -2 lines 0 comments Download

Messages

Total messages: 18 (0 generated)
ajuma
PTAL. I think a better long-term approach is to switch from lazily setting the frame ...
7 years, 7 months ago (2013-05-16 15:21:56 UTC) #1
danakj
On 2013/05/16 15:21:56, ajuma wrote: > PTAL. > > I think a better long-term approach ...
7 years, 7 months ago (2013-05-16 15:28:43 UTC) #2
danakj
https://codereview.chromium.org/15139007/diff/1/cc/trees/layer_tree_host_unittest.cc File cc/trees/layer_tree_host_unittest.cc (right): https://codereview.chromium.org/15139007/diff/1/cc/trees/layer_tree_host_unittest.cc#newcode651 cc/trees/layer_tree_host_unittest.cc:651: frame_ = 1; I think you can just EndTest() ...
7 years, 7 months ago (2013-05-16 15:37:18 UTC) #3
ajuma
PTAL. On 2013/05/16 15:28:43, danakj wrote: > On 2013/05/16 15:21:56, ajuma wrote: > > PTAL. ...
7 years, 7 months ago (2013-05-16 17:24:34 UTC) #4
danakj
Thanks! LGTM with a small request for the test https://codereview.chromium.org/15139007/diff/11001/cc/trees/layer_tree_host_unittest.cc File cc/trees/layer_tree_host_unittest.cc (right): https://codereview.chromium.org/15139007/diff/11001/cc/trees/layer_tree_host_unittest.cc#newcode692 cc/trees/layer_tree_host_unittest.cc:692: ...
7 years, 7 months ago (2013-05-16 17:42:38 UTC) #5
brianderson
https://codereview.chromium.org/15139007/diff/11001/cc/trees/thread_proxy.cc File cc/trees/thread_proxy.cc (right): https://codereview.chromium.org/15139007/diff/11001/cc/trees/thread_proxy.cc#newcode1035 cc/trees/thread_proxy.cc:1035: layer_tree_host_impl_->BeginNextFrame(); I know this is tangential to what you ...
7 years, 7 months ago (2013-05-16 18:16:00 UTC) #6
danakj
https://codereview.chromium.org/15139007/diff/11001/cc/trees/thread_proxy.cc File cc/trees/thread_proxy.cc (right): https://codereview.chromium.org/15139007/diff/11001/cc/trees/thread_proxy.cc#newcode1035 cc/trees/thread_proxy.cc:1035: layer_tree_host_impl_->BeginNextFrame(); On 2013/05/16 18:16:00, Brian Anderson wrote: > I ...
7 years, 7 months ago (2013-05-16 18:18:09 UTC) #7
danakj
https://codereview.chromium.org/15139007/diff/11001/cc/trees/thread_proxy.cc File cc/trees/thread_proxy.cc (right): https://codereview.chromium.org/15139007/diff/11001/cc/trees/thread_proxy.cc#newcode1035 cc/trees/thread_proxy.cc:1035: layer_tree_host_impl_->BeginNextFrame(); On 2013/05/16 18:18:09, danakj wrote: > On 2013/05/16 ...
7 years, 7 months ago (2013-05-16 18:24:07 UTC) #8
ajuma
On 2013/05/16 17:42:38, danakj wrote: > Thanks! LGTM with a small request for the test ...
7 years, 7 months ago (2013-05-16 18:33:33 UTC) #9
danakj
On Thu, May 16, 2013 at 2:33 PM, <ajuma@chromium.org> wrote: > This won't work for ...
7 years, 7 months ago (2013-05-16 18:50:42 UTC) #10
ajuma
https://codereview.chromium.org/15139007/diff/11001/cc/trees/layer_tree_host_unittest.cc File cc/trees/layer_tree_host_unittest.cc (right): https://codereview.chromium.org/15139007/diff/11001/cc/trees/layer_tree_host_unittest.cc#newcode692 cc/trees/layer_tree_host_unittest.cc:692: impl->SetNeedsRedraw(); On 2013/05/16 17:42:38, danakj wrote: > Can you ...
7 years, 7 months ago (2013-05-16 19:50:01 UTC) #11
danakj
LGTM if brian's happy!
7 years, 7 months ago (2013-05-16 19:51:49 UTC) #12
brianderson
lgtm too
7 years, 7 months ago (2013-05-16 19:54:23 UTC) #13
ajuma
PTAL. https://chromiumcodereview.appspot.com/15139007/diff/48001/cc/trees/layer_tree_host_unittest.cc File cc/trees/layer_tree_host_unittest.cc (right): https://chromiumcodereview.appspot.com/15139007/diff/48001/cc/trees/layer_tree_host_unittest.cc#newcode703 cc/trees/layer_tree_host_unittest.cc:703: while (first_frame_time_ == base::TimeTicks::Now()); This test (and the ...
7 years, 7 months ago (2013-05-17 13:36:45 UTC) #14
danakj
LGTM https://chromiumcodereview.appspot.com/15139007/diff/48001/cc/trees/layer_tree_host_unittest.cc File cc/trees/layer_tree_host_unittest.cc (right): https://chromiumcodereview.appspot.com/15139007/diff/48001/cc/trees/layer_tree_host_unittest.cc#newcode663 cc/trees/layer_tree_host_unittest.cc:663: while (first_frame_time_ == base::TimeTicks::Now()); nit: use {} instead ...
7 years, 7 months ago (2013-05-17 13:39:36 UTC) #15
ajuma
https://codereview.chromium.org/15139007/diff/48001/cc/trees/layer_tree_host_unittest.cc File cc/trees/layer_tree_host_unittest.cc (right): https://codereview.chromium.org/15139007/diff/48001/cc/trees/layer_tree_host_unittest.cc#newcode663 cc/trees/layer_tree_host_unittest.cc:663: while (first_frame_time_ == base::TimeTicks::Now()); On 2013/05/17 13:39:36, danakj wrote: ...
7 years, 7 months ago (2013-05-17 13:46:49 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ajuma@chromium.org/15139007/54001
7 years, 7 months ago (2013-05-17 17:26:26 UTC) #17
commit-bot: I haz the power
7 years, 7 months ago (2013-05-17 23:22:45 UTC) #18
Message was sent while issue was closed.
Change committed as 200920

Powered by Google App Engine
This is Rietveld 408576698