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

Side by Side Diff: services/ui/ws/gpu_service_proxy.h

Issue 2342003003: [WIP] Mus: Pass the mojo connector to OzonePlatform::InitializeForGPU (Closed)
Patch Set: Created 4 years, 3 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 | « services/ui/service.cc ('k') | services/ui/ws/gpu_service_proxy.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 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_WS_GPU_SERVICE_PROXY_H_ 5 #ifndef SERVICES_UI_WS_GPU_SERVICE_PROXY_H_
6 #define SERVICES_UI_WS_GPU_SERVICE_PROXY_H_ 6 #define SERVICES_UI_WS_GPU_SERVICE_PROXY_H_
7 7
8 #include "base/single_thread_task_runner.h" 8 #include "base/single_thread_task_runner.h"
9 #include "base/synchronization/waitable_event.h" 9 #include "base/synchronization/waitable_event.h"
10 #include "base/threading/thread.h" 10 #include "base/threading/thread.h"
11 #include "gpu/config/gpu_info.h" 11 #include "gpu/config/gpu_info.h"
12 #include "gpu/ipc/client/gpu_channel_host.h" 12 #include "gpu/ipc/client/gpu_channel_host.h"
13 #include "mojo/public/cpp/bindings/binding_set.h" 13 #include "mojo/public/cpp/bindings/binding_set.h"
14 #include "mojo/public/cpp/bindings/interface_request.h" 14 #include "mojo/public/cpp/bindings/interface_request.h"
15 #include "services/ui/gpu/gpu_main.h" 15 #include "services/ui/gpu/gpu_main.h"
16 #include "services/ui/gpu/interfaces/gpu_service_internal.mojom.h" 16 #include "services/ui/gpu/interfaces/gpu_service_internal.mojom.h"
17 #include "services/ui/public/interfaces/gpu_memory_buffer.mojom.h" 17 #include "services/ui/public/interfaces/gpu_memory_buffer.mojom.h"
18 #include "services/ui/public/interfaces/gpu_service.mojom.h" 18 #include "services/ui/public/interfaces/gpu_service.mojom.h"
19 19
20 namespace shell {
21 class Connector;
22 }
23
20 namespace gpu { 24 namespace gpu {
21 class GpuChannelHost; 25 class GpuChannelHost;
22 } 26 }
23 27
24 namespace ui { 28 namespace ui {
25 29
26 class GpuServiceInternal; 30 class GpuServiceInternal;
27 31
28 namespace ws { 32 namespace ws {
29 33
30 class GpuServiceProxyDelegate; 34 class GpuServiceProxyDelegate;
31 class MusGpuMemoryBufferManager; 35 class MusGpuMemoryBufferManager;
32 36
33 // The proxy implementation that relays requests from clients to the real 37 // The proxy implementation that relays requests from clients to the real
34 // service implementation in the GPU process over mojom.GpuServiceInternal. 38 // service implementation in the GPU process over mojom.GpuServiceInternal.
35 class GpuServiceProxy : public mojom::GpuService, 39 class GpuServiceProxy : public mojom::GpuService,
36 public gpu::GpuChannelHostFactory { 40 public gpu::GpuChannelHostFactory {
37 public: 41 public:
38 explicit GpuServiceProxy(GpuServiceProxyDelegate* delegate); 42 explicit GpuServiceProxy(GpuServiceProxyDelegate* delegate,
43 shell::Connector*);
39 ~GpuServiceProxy() override; 44 ~GpuServiceProxy() override;
40 45
41 void Add(mojom::GpuServiceRequest request); 46 void Add(mojom::GpuServiceRequest request);
42 47
43 private: 48 private:
44 void OnInitialized(const gpu::GPUInfo& gpu_info); 49 void OnInitialized(const gpu::GPUInfo& gpu_info);
45 void OnGpuChannelEstablished(const EstablishGpuChannelCallback& callback, 50 void OnGpuChannelEstablished(const EstablishGpuChannelCallback& callback,
46 int32_t client_id, 51 int32_t client_id,
47 mojo::ScopedMessagePipeHandle channel_handle); 52 mojo::ScopedMessagePipeHandle channel_handle);
48 void OnInternalGpuChannelEstablished( 53 void OnInternalGpuChannelEstablished(
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 std::unique_ptr<MusGpuMemoryBufferManager> gpu_memory_buffer_manager_; 85 std::unique_ptr<MusGpuMemoryBufferManager> gpu_memory_buffer_manager_;
81 GpuMain gpu_main_; 86 GpuMain gpu_main_;
82 87
83 DISALLOW_COPY_AND_ASSIGN(GpuServiceProxy); 88 DISALLOW_COPY_AND_ASSIGN(GpuServiceProxy);
84 }; 89 };
85 90
86 } // namespace ws 91 } // namespace ws
87 } // namespace ui 92 } // namespace ui
88 93
89 #endif // SERVICES_UI_WS_GPU_SERVICE_PROXY_H_ 94 #endif // SERVICES_UI_WS_GPU_SERVICE_PROXY_H_
OLDNEW
« no previous file with comments | « services/ui/service.cc ('k') | services/ui/ws/gpu_service_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698