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

Side by Side Diff: cc/scheduler/begin_frame_source.h

Issue 2767933002: [cc] Don't send missed BeginFrames with past deadline.
Patch Set: add ExternalBFS tests, don't check in DelayBasedBFS. Created 3 years, 8 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
« no previous file with comments | « no previous file | cc/scheduler/begin_frame_source.cc » ('j') | 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 #ifndef CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_ 5 #ifndef CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_
6 #define CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_ 6 #define CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 const BeginFrameAck& ack) override; 304 const BeginFrameAck& ack) override;
305 bool IsThrottled() const override; 305 bool IsThrottled() const override;
306 306
307 void OnSetBeginFrameSourcePaused(bool paused); 307 void OnSetBeginFrameSourcePaused(bool paused);
308 void OnBeginFrame(const BeginFrameArgs& args); 308 void OnBeginFrame(const BeginFrameArgs& args);
309 309
310 protected: 310 protected:
311 void MaybeFinishFrame(); 311 void MaybeFinishFrame();
312 void FinishFrame(); 312 void FinishFrame();
313 313
314 // Virtual for testing.
315 virtual base::TimeTicks Now() const;
316
314 BeginFrameArgs missed_begin_frame_args_; 317 BeginFrameArgs missed_begin_frame_args_;
315 std::unordered_set<BeginFrameObserver*> observers_; 318 std::unordered_set<BeginFrameObserver*> observers_;
316 ExternalBeginFrameSourceClient* client_; 319 ExternalBeginFrameSourceClient* client_;
317 bool paused_ = false; 320 bool paused_ = false;
318 bool frame_active_ = false; 321 bool frame_active_ = false;
319 BeginFrameObserverAckTracker ack_tracker_; 322 BeginFrameObserverAckTracker ack_tracker_;
320 323
321 private: 324 private:
322 DISALLOW_COPY_AND_ASSIGN(ExternalBeginFrameSource); 325 DISALLOW_COPY_AND_ASSIGN(ExternalBeginFrameSource);
323 }; 326 };
324 327
325 } // namespace cc 328 } // namespace cc
326 329
327 #endif // CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_ 330 #endif // CC_SCHEDULER_BEGIN_FRAME_SOURCE_H_
OLDNEW
« no previous file with comments | « no previous file | cc/scheduler/begin_frame_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698