| 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 SERVICES_UI_GPU_GPU_MAIN_H_ | 5 #ifndef SERVICES_UI_GPU_GPU_MAIN_H_ |
| 6 #define SERVICES_UI_GPU_GPU_MAIN_H_ | 6 #define SERVICES_UI_GPU_GPU_MAIN_H_ |
| 7 | 7 |
| 8 #include "base/threading/thread.h" | 8 #include "base/threading/thread.h" |
| 9 #include "gpu/ipc/in_process_command_buffer.h" | 9 #include "gpu/ipc/in_process_command_buffer.h" |
| 10 #include "gpu/ipc/service/gpu_init.h" | 10 #include "gpu/ipc/service/gpu_init.h" |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 // If the gpu service is not yet ready then we stash pending MessagePipes in | 75 // If the gpu service is not yet ready then we stash pending MessagePipes in |
| 76 // these member variables. | 76 // these member variables. |
| 77 cc::mojom::DisplayCompositorRequest pending_display_compositor_request_; | 77 cc::mojom::DisplayCompositorRequest pending_display_compositor_request_; |
| 78 cc::mojom::DisplayCompositorClientPtrInfo | 78 cc::mojom::DisplayCompositorClientPtrInfo |
| 79 pending_display_compositor_client_info_; | 79 pending_display_compositor_client_info_; |
| 80 | 80 |
| 81 std::unique_ptr<DisplayCompositor> display_compositor_; | 81 std::unique_ptr<DisplayCompositor> display_compositor_; |
| 82 | 82 |
| 83 std::unique_ptr<gpu::GpuMemoryBufferFactory> gpu_memory_buffer_factory_; | 83 std::unique_ptr<gpu::GpuMemoryBufferFactory> gpu_memory_buffer_factory_; |
| 84 | 84 |
| 85 // The main thread for GpuService. | 85 // The main thread for Gpu. |
| 86 base::Thread gpu_thread_; | 86 base::Thread gpu_thread_; |
| 87 | 87 |
| 88 // The thread that handles IO events for GpuService. | 88 // The thread that handles IO events for Gpu. |
| 89 base::Thread io_thread_; | 89 base::Thread io_thread_; |
| 90 | 90 |
| 91 // The display compositor gets its own thread in mus-gpu. The gpu service, | 91 // The display compositor gets its own thread in mus-gpu. The gpu service, |
| 92 // where GL commands are processed resides on its own thread. Various | 92 // where GL commands are processed resides on its own thread. Various |
| 93 // components of the display compositor such as Display, ResourceProvider, | 93 // components of the display compositor such as Display, ResourceProvider, |
| 94 // and GLRenderer block on sync tokens from other command buffers. Thus, | 94 // and GLRenderer block on sync tokens from other command buffers. Thus, |
| 95 // the gpu service must live on a separate thread. | 95 // the gpu service must live on a separate thread. |
| 96 base::Thread compositor_thread_; | 96 base::Thread compositor_thread_; |
| 97 | 97 |
| 98 mojo::Binding<mojom::GpuMain> binding_; | 98 mojo::Binding<mojom::GpuMain> binding_; |
| 99 | 99 |
| 100 DISALLOW_COPY_AND_ASSIGN(GpuMain); | 100 DISALLOW_COPY_AND_ASSIGN(GpuMain); |
| 101 }; | 101 }; |
| 102 | 102 |
| 103 } // namespace ui | 103 } // namespace ui |
| 104 | 104 |
| 105 #endif // SERVICES_UI_GPU_GPU_MAIN_H_ | 105 #endif // SERVICES_UI_GPU_GPU_MAIN_H_ |
| OLD | NEW |