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

Side by Side Diff: cc/output/output_surface_client.h

Issue 16833003: cc: Emulate BeginFrame in OutputSurfaces that don't support it natively (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 7 years, 6 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 | « cc/output/output_surface.cc ('k') | cc/output/output_surface_unittest.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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ 5 #ifndef CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_
6 #define CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ 6 #define CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
11 #include "cc/output/context_provider.h" 11 #include "cc/output/context_provider.h"
12 #include "ui/gfx/rect.h" 12 #include "ui/gfx/rect.h"
13 13
14 namespace gfx { 14 namespace gfx {
15 class Transform; 15 class Transform;
16 } 16 }
17 17
18 namespace cc { 18 namespace cc {
19 19
20 class CompositorFrameAck; 20 class CompositorFrameAck;
21 21
22 class CC_EXPORT OutputSurfaceClient { 22 class CC_EXPORT OutputSurfaceClient {
23 public: 23 public:
24 // Called to synchronously re-initialize using the Context3D. Upon returning 24 // Called to synchronously re-initialize using the Context3D. Upon returning
25 // the compositor should be able to draw using GL what was previously 25 // the compositor should be able to draw using GL what was previously
26 // committed. 26 // committed.
27 virtual bool DeferredInitialize( 27 virtual bool DeferredInitialize(
28 scoped_refptr<ContextProvider> offscreen_context_provider) = 0; 28 scoped_refptr<ContextProvider> offscreen_context_provider) = 0;
29 virtual void SetNeedsRedrawRect(gfx::Rect damage_rect) = 0; 29 virtual void SetNeedsRedrawRect(gfx::Rect damage_rect) = 0;
30 virtual void OnVSyncParametersChanged(base::TimeTicks timebase,
31 base::TimeDelta interval) = 0;
32 virtual void BeginFrame(base::TimeTicks frame_time) = 0; 30 virtual void BeginFrame(base::TimeTicks frame_time) = 0;
33 virtual void OnSwapBuffersComplete(const CompositorFrameAck* ack) = 0; 31 virtual void OnSwapBuffersComplete(const CompositorFrameAck* ack) = 0;
34 virtual void DidLoseOutputSurface() = 0; 32 virtual void DidLoseOutputSurface() = 0;
35 virtual void SetExternalDrawConstraints(const gfx::Transform& transform, 33 virtual void SetExternalDrawConstraints(const gfx::Transform& transform,
36 gfx::Rect viewport) = 0; 34 gfx::Rect viewport) = 0;
37 35
38 protected: 36 protected:
39 virtual ~OutputSurfaceClient() {} 37 virtual ~OutputSurfaceClient() {}
40 }; 38 };
41 39
42 } // namespace cc 40 } // namespace cc
43 41
44 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ 42 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_
OLDNEW
« no previous file with comments | « cc/output/output_surface.cc ('k') | cc/output/output_surface_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698