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

Side by Side Diff: mojo/examples/compositor_app/compositor_host.h

Issue 132163009: [#6]Pass gfx structs by const ref (gfx::Vector2d) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on TOT Created 6 years, 10 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
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 MOJO_EXAMPLES_COMPOSITOR_APP_COMPOSITOR_HOST_H_ 5 #ifndef MOJO_EXAMPLES_COMPOSITOR_APP_COMPOSITOR_HOST_H_
6 #define MOJO_EXAMPLES_COMPOSITOR_APP_COMPOSITOR_HOST_H_ 6 #define MOJO_EXAMPLES_COMPOSITOR_APP_COMPOSITOR_HOST_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/threading/thread.h" 10 #include "base/threading/thread.h"
(...skipping 15 matching lines...) Expand all
26 virtual ~CompositorHost(); 26 virtual ~CompositorHost();
27 27
28 void SetSize(gfx::Size viewport_size); 28 void SetSize(gfx::Size viewport_size);
29 void DidCreateContext(); 29 void DidCreateContext();
30 30
31 // cc::LayerTreeHostClient implementation. 31 // cc::LayerTreeHostClient implementation.
32 virtual void WillBeginMainFrame(int frame_id) OVERRIDE; 32 virtual void WillBeginMainFrame(int frame_id) OVERRIDE;
33 virtual void DidBeginMainFrame() OVERRIDE; 33 virtual void DidBeginMainFrame() OVERRIDE;
34 virtual void Animate(double frame_begin_time) OVERRIDE; 34 virtual void Animate(double frame_begin_time) OVERRIDE;
35 virtual void Layout() OVERRIDE; 35 virtual void Layout() OVERRIDE;
36 virtual void ApplyScrollAndScale(gfx::Vector2d scroll_delta, 36 virtual void ApplyScrollAndScale(const gfx::Vector2d& scroll_delta,
37 float page_scale) OVERRIDE; 37 float page_scale) OVERRIDE;
38 virtual scoped_ptr<cc::OutputSurface> CreateOutputSurface(bool fallback) 38 virtual scoped_ptr<cc::OutputSurface> CreateOutputSurface(bool fallback)
39 OVERRIDE; 39 OVERRIDE;
40 virtual void DidInitializeOutputSurface(bool success) OVERRIDE; 40 virtual void DidInitializeOutputSurface(bool success) OVERRIDE;
41 virtual void WillCommit() OVERRIDE; 41 virtual void WillCommit() OVERRIDE;
42 virtual void DidCommit() OVERRIDE; 42 virtual void DidCommit() OVERRIDE;
43 virtual void DidCommitAndDrawFrame() OVERRIDE; 43 virtual void DidCommitAndDrawFrame() OVERRIDE;
44 virtual void DidCompleteSwapBuffers() OVERRIDE; 44 virtual void DidCompleteSwapBuffers() OVERRIDE;
45 virtual scoped_refptr<cc::ContextProvider> OffscreenContextProvider() 45 virtual scoped_refptr<cc::ContextProvider> OffscreenContextProvider()
46 OVERRIDE; 46 OVERRIDE;
47 47
48 private: 48 private:
49 void SetupScene(); 49 void SetupScene();
50 50
51 GLES2ClientImpl* gles2_client_impl_; 51 GLES2ClientImpl* gles2_client_impl_;
52 scoped_ptr<cc::LayerTreeHost> tree_; 52 scoped_ptr<cc::LayerTreeHost> tree_;
53 scoped_refptr<cc::Layer> child_layer_; 53 scoped_refptr<cc::Layer> child_layer_;
54 base::Thread compositor_thread_; 54 base::Thread compositor_thread_;
55 }; 55 };
56 56
57 } // namespace examples 57 } // namespace examples
58 } // namespace mojo 58 } // namespace mojo
59 59
60 #endif // MOJO_EXAMPLES_COMPOSITOR_APP_COMPOSITOR_HOST_H_ 60 #endif // MOJO_EXAMPLES_COMPOSITOR_APP_COMPOSITOR_HOST_H_
OLDNEW
« no previous file with comments | « content/test/web_layer_tree_view_impl_for_testing.cc ('k') | mojo/examples/compositor_app/compositor_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698