OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 BLIMP_CLIENT_SUPPORT_COMPOSITOR_COMPOSITOR_DEPENDENCIES_IMPL_H_ | 5 #ifndef BLIMP_CLIENT_SUPPORT_COMPOSITOR_COMPOSITOR_DEPENDENCIES_IMPL_H_ |
6 #define BLIMP_CLIENT_SUPPORT_COMPOSITOR_COMPOSITOR_DEPENDENCIES_IMPL_H_ | 6 #define BLIMP_CLIENT_SUPPORT_COMPOSITOR_COMPOSITOR_DEPENDENCIES_IMPL_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "blimp/client/public/compositor/compositor_dependencies.h" | 10 #include "blimp/client/public/compositor/compositor_dependencies.h" |
11 | 11 |
12 namespace cc { | 12 namespace cc { |
13 class ContextProvider; | 13 class ContextProvider; |
14 } | 14 } |
15 | 15 |
16 namespace blimp { | 16 namespace blimp { |
17 namespace client { | 17 namespace client { |
18 | 18 |
19 class BlimpGpuMemoryBufferManager; | 19 class BlimpGpuMemoryBufferManager; |
20 | 20 |
21 class CompositorDependenciesImpl : public CompositorDependencies { | 21 class CompositorDependenciesImpl : public CompositorDependencies { |
22 public: | 22 public: |
23 CompositorDependenciesImpl(); | 23 CompositorDependenciesImpl(); |
24 ~CompositorDependenciesImpl() override; | 24 ~CompositorDependenciesImpl() override; |
25 | 25 |
26 // CompositorDependencies implementation. | 26 // CompositorDependencies implementation. |
27 cc::LayerTreeSettings* GetLayerTreeSettings() override; | 27 cc::LayerTreeSettings* GetLayerTreeSettings() override; |
28 gpu::GpuMemoryBufferManager* GetGpuMemoryBufferManager() override; | 28 gpu::GpuMemoryBufferManager* GetGpuMemoryBufferManager() override; |
29 cc::SurfaceManager* GetSurfaceManager() override; | 29 cc::SurfaceManager* GetSurfaceManager() override; |
30 uint32_t AllocateSurfaceId() override; | 30 uint32_t AllocateSurfaceClientId() override; |
31 void GetContextProvider(const ContextProviderCallback& callback) override; | 31 void GetContextProviders(const ContextProviderCallback& callback) override; |
32 | 32 |
33 private: | 33 private: |
34 std::unique_ptr<cc::LayerTreeSettings> settings_; | 34 std::unique_ptr<cc::LayerTreeSettings> settings_; |
35 std::unique_ptr<BlimpGpuMemoryBufferManager> gpu_memory_buffer_manager_; | 35 std::unique_ptr<BlimpGpuMemoryBufferManager> gpu_memory_buffer_manager_; |
36 std::unique_ptr<cc::SurfaceManager> surface_manager_; | 36 std::unique_ptr<cc::SurfaceManager> surface_manager_; |
37 uint32_t next_surface_id_; | 37 uint32_t next_surface_id_; |
38 | 38 |
39 DISALLOW_COPY_AND_ASSIGN(CompositorDependenciesImpl); | 39 DISALLOW_COPY_AND_ASSIGN(CompositorDependenciesImpl); |
40 }; | 40 }; |
41 | 41 |
42 } // namespace client | 42 } // namespace client |
43 } // namespace blimp | 43 } // namespace blimp |
44 | 44 |
45 #endif // BLIMP_CLIENT_SUPPORT_COMPOSITOR_COMPOSITOR_DEPENDENCIES_IMPL_H_ | 45 #endif // BLIMP_CLIENT_SUPPORT_COMPOSITOR_COMPOSITOR_DEPENDENCIES_IMPL_H_ |
OLD | NEW |