| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ |
| 6 #define CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| 11 | 11 |
| 12 #include "base/cancelable_callback.h" | 12 #include "base/cancelable_callback.h" |
| 13 #include "base/compiler_specific.h" | 13 #include "base/compiler_specific.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
| 16 #include "base/observer_list.h" | 16 #include "base/observer_list.h" |
| 17 #include "base/timer/timer.h" | 17 #include "base/timer/timer.h" |
| 18 #include "cc/scheduler/begin_frame_source.h" |
| 18 #include "cc/trees/layer_tree_host_client.h" | 19 #include "cc/trees/layer_tree_host_client.h" |
| 19 #include "cc/trees/layer_tree_host_single_thread_client.h" | 20 #include "cc/trees/layer_tree_host_single_thread_client.h" |
| 20 #include "content/common/content_export.h" | 21 #include "content/common/content_export.h" |
| 21 #include "content/common/gpu/client/context_provider_command_buffer.h" | 22 #include "content/common/gpu/client/context_provider_command_buffer.h" |
| 22 #include "content/public/browser/android/compositor.h" | 23 #include "content/public/browser/android/compositor.h" |
| 23 #include "gpu/command_buffer/common/capabilities.h" | 24 #include "gpu/command_buffer/common/capabilities.h" |
| 24 #include "gpu/ipc/common/surface_handle.h" | 25 #include "gpu/ipc/common/surface_handle.h" |
| 25 #include "third_party/khronos/GLES2/gl2.h" | 26 #include "third_party/khronos/GLES2/gl2.h" |
| 26 #include "ui/android/context_provider_factory.h" | 27 #include "ui/android/context_provider_factory.h" |
| 27 #include "ui/android/resources/resource_manager_impl.h" | 28 #include "ui/android/resources/resource_manager_impl.h" |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 // Subtree for hidden layers with CopyOutputRequests on them. | 143 // Subtree for hidden layers with CopyOutputRequests on them. |
| 143 scoped_refptr<cc::Layer> readback_layer_tree_; | 144 scoped_refptr<cc::Layer> readback_layer_tree_; |
| 144 | 145 |
| 145 // Destruction order matters here: | 146 // Destruction order matters here: |
| 146 std::unique_ptr<cc::SurfaceIdAllocator> surface_id_allocator_; | 147 std::unique_ptr<cc::SurfaceIdAllocator> surface_id_allocator_; |
| 147 base::ObserverList<VSyncObserver, true> observer_list_; | 148 base::ObserverList<VSyncObserver, true> observer_list_; |
| 148 std::unique_ptr<cc::LayerTreeHost> host_; | 149 std::unique_ptr<cc::LayerTreeHost> host_; |
| 149 ui::ResourceManagerImpl resource_manager_; | 150 ui::ResourceManagerImpl resource_manager_; |
| 150 | 151 |
| 151 std::unique_ptr<cc::Display> display_; | 152 std::unique_ptr<cc::Display> display_; |
| 153 std::unique_ptr<cc::BeginFrameSource> begin_frame_source_; |
| 152 | 154 |
| 153 gfx::Size size_; | 155 gfx::Size size_; |
| 154 bool has_transparent_background_; | 156 bool has_transparent_background_; |
| 155 float device_scale_factor_; | 157 float device_scale_factor_; |
| 156 | 158 |
| 157 ANativeWindow* window_; | 159 ANativeWindow* window_; |
| 158 gpu::SurfaceHandle surface_handle_; | 160 gpu::SurfaceHandle surface_handle_; |
| 159 | 161 |
| 160 CompositorClient* client_; | 162 CompositorClient* client_; |
| 161 | 163 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 179 gpu::Capabilities gpu_capabilities_; | 181 gpu::Capabilities gpu_capabilities_; |
| 180 bool needs_begin_frames_; | 182 bool needs_begin_frames_; |
| 181 base::WeakPtrFactory<CompositorImpl> weak_factory_; | 183 base::WeakPtrFactory<CompositorImpl> weak_factory_; |
| 182 | 184 |
| 183 DISALLOW_COPY_AND_ASSIGN(CompositorImpl); | 185 DISALLOW_COPY_AND_ASSIGN(CompositorImpl); |
| 184 }; | 186 }; |
| 185 | 187 |
| 186 } // namespace content | 188 } // namespace content |
| 187 | 189 |
| 188 #endif // CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ | 190 #endif // CONTENT_BROWSER_RENDERER_HOST_COMPOSITOR_IMPL_ANDROID_H_ |
| OLD | NEW |