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

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

Issue 12674030: cc: Hook vsync time source to output surface (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Review tweaks. Created 7 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « cc/output/output_surface_client.h ('k') | cc/scheduler/vsync_time_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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_VSYNC_TIME_SOURCE_H_ 5 #ifndef CC_SCHEDULER_VSYNC_TIME_SOURCE_H_
6 #define CC_SCHEDULER_VSYNC_TIME_SOURCE_H_ 6 #define CC_SCHEDULER_VSYNC_TIME_SOURCE_H_
7 7
8 #include "cc/base/cc_export.h" 8 #include "cc/base/cc_export.h"
9 #include "cc/scheduler/time_source.h" 9 #include "cc/scheduler/time_source.h"
10 10
(...skipping 15 matching lines...) Expand all
26 virtual void RequestVSyncNotification(VSyncClient* client) = 0; 26 virtual void RequestVSyncNotification(VSyncClient* client) = 0;
27 27
28 protected: 28 protected:
29 virtual ~VSyncProvider() {} 29 virtual ~VSyncProvider() {}
30 }; 30 };
31 31
32 // This timer implements a time source that is explicitly triggered by an 32 // This timer implements a time source that is explicitly triggered by an
33 // external vsync signal. 33 // external vsync signal.
34 class CC_EXPORT VSyncTimeSource : public TimeSource, public VSyncClient { 34 class CC_EXPORT VSyncTimeSource : public TimeSource, public VSyncClient {
35 public: 35 public:
36 static scoped_refptr<VSyncTimeSource> create(VSyncProvider* vsync_provider); 36 static scoped_refptr<VSyncTimeSource> Create(VSyncProvider* vsync_provider);
37 37
38 // TimeSource implementation 38 // TimeSource implementation
39 virtual void SetClient(TimeSourceClient* client) OVERRIDE; 39 virtual void SetClient(TimeSourceClient* client) OVERRIDE;
40 virtual void SetTimebaseAndInterval(base::TimeTicks timebase, 40 virtual void SetTimebaseAndInterval(base::TimeTicks timebase,
41 base::TimeDelta interval) OVERRIDE; 41 base::TimeDelta interval) OVERRIDE;
42 virtual void SetActive(bool active) OVERRIDE; 42 virtual void SetActive(bool active) OVERRIDE;
43 virtual bool Active() const OVERRIDE; 43 virtual bool Active() const OVERRIDE;
44 virtual base::TimeTicks LastTickTime() OVERRIDE; 44 virtual base::TimeTicks LastTickTime() OVERRIDE;
45 virtual base::TimeTicks NextTickTime() OVERRIDE; 45 virtual base::TimeTicks NextTickTime() OVERRIDE;
46 46
(...skipping 11 matching lines...) Expand all
58 58
59 VSyncProvider* vsync_provider_; 59 VSyncProvider* vsync_provider_;
60 TimeSourceClient* client_; 60 TimeSourceClient* client_;
61 61
62 DISALLOW_COPY_AND_ASSIGN(VSyncTimeSource); 62 DISALLOW_COPY_AND_ASSIGN(VSyncTimeSource);
63 }; 63 };
64 64
65 } // namespace cc 65 } // namespace cc
66 66
67 #endif // CC_SCHEDULER_VSYNC_TIME_SOURCE_H_ 67 #endif // CC_SCHEDULER_VSYNC_TIME_SOURCE_H_
OLDNEW
« no previous file with comments | « cc/output/output_surface_client.h ('k') | cc/scheduler/vsync_time_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698