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

Side by Side Diff: chrome/browser/chromeos/arc/video/gpu_arc_video_service_host.h

Issue 2919193002: ArcBridge: Rename VideoAcceleratorService to VideoDecodeAccelerator. (Closed)
Patch Set: Address review comments Created 3 years, 6 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 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 CHROME_BROWSER_CHROMEOS_ARC_VIDEO_GPU_ARC_VIDEO_SERVICE_HOST_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_ARC_VIDEO_GPU_ARC_VIDEO_SERVICE_HOST_H_
6 #define CHROME_BROWSER_CHROMEOS_ARC_VIDEO_GPU_ARC_VIDEO_SERVICE_HOST_H_ 6 #define CHROME_BROWSER_CHROMEOS_ARC_VIDEO_GPU_ARC_VIDEO_SERVICE_HOST_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "components/arc/arc_service.h" 9 #include "components/arc/arc_service.h"
10 #include "components/arc/common/video.mojom.h" 10 #include "components/arc/common/video.mojom.h"
11 #include "components/arc/instance_holder.h" 11 #include "components/arc/instance_holder.h"
12 #include "mojo/public/cpp/bindings/binding.h" 12 #include "mojo/public/cpp/bindings/binding.h"
13 13
14 namespace arc { 14 namespace arc {
15 15
16 class ArcBridgeService; 16 class ArcBridgeService;
17 17
18 // This class takes requests for creating channels of video accelerators from 18 // This class takes requests for accessing the VideoAcceleratorFactory, from
19 // arc::VideoInstance and forwards these requests to GpuArcVideoServce. It also 19 // which video decode (or encode) accelerators could be created.
20 // returns the created channels back to the arc::VideoInstance.
21 // 20 //
22 // This class is the proxy end of GpuArcVideoService and runs in the browser 21 // This class runs in the browser process, while the created instances of
23 // process. The corresponding end "GpuArcVideoService" runs in the GPU process. 22 // VideoDecodeAccelerator or VideoEncodeAccelerator run in the GPU process.
24 // 23 //
25 // Lives on the UI thread. 24 // Lives on the UI thread.
26 class GpuArcVideoServiceHost 25 class GpuArcVideoServiceHost
27 : public ArcService, 26 : public ArcService,
28 public InstanceHolder<mojom::VideoInstance>::Observer, 27 public InstanceHolder<mojom::VideoInstance>::Observer,
29 public mojom::VideoHost { 28 public mojom::VideoHost {
30 public: 29 public:
31 explicit GpuArcVideoServiceHost(ArcBridgeService* bridge_service); 30 explicit GpuArcVideoServiceHost(ArcBridgeService* bridge_service);
32 ~GpuArcVideoServiceHost() override; 31 ~GpuArcVideoServiceHost() override;
33 32
34 // arc::InstanceHolder<mojom::VideoInstance>::Observer implementation. 33 // arc::InstanceHolder<mojom::VideoInstance>::Observer implementation.
35 void OnInstanceReady() override; 34 void OnInstanceReady() override;
36 35
37 // arc::mojom::VideoHost implementation. 36 // arc::mojom::VideoHost implementation.
38 void OnBootstrapVideoAcceleratorFactory( 37 void OnBootstrapVideoAcceleratorFactory(
39 const OnBootstrapVideoAcceleratorFactoryCallback& callback) override; 38 const OnBootstrapVideoAcceleratorFactoryCallback& callback) override;
40 39
41 private: 40 private:
42 mojo::Binding<mojom::VideoHost> binding_; 41 mojo::Binding<mojom::VideoHost> binding_;
43 42
44 DISALLOW_COPY_AND_ASSIGN(GpuArcVideoServiceHost); 43 DISALLOW_COPY_AND_ASSIGN(GpuArcVideoServiceHost);
45 }; 44 };
46 45
47 } // namespace arc 46 } // namespace arc
48 47
49 #endif // CHROME_BROWSER_CHROMEOS_ARC_VIDEO_GPU_ARC_VIDEO_SERVICE_HOST_H_ 48 #endif // CHROME_BROWSER_CHROMEOS_ARC_VIDEO_GPU_ARC_VIDEO_SERVICE_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698