OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 UI_OZONE_PLATFORM_CAST_OVERLAY_MANAGER_CAST_H_ | 5 #ifndef UI_OZONE_PLATFORM_CAST_OVERLAY_MANAGER_CAST_H_ |
6 #define UI_OZONE_PLATFORM_CAST_OVERLAY_MANAGER_CAST_H_ | 6 #define UI_OZONE_PLATFORM_CAST_OVERLAY_MANAGER_CAST_H_ |
7 | 7 |
| 8 #include <memory> |
| 9 |
8 #include "base/callback.h" | 10 #include "base/callback.h" |
9 #include "base/macros.h" | 11 #include "base/macros.h" |
10 #include "base/memory/scoped_ptr.h" | |
11 #include "chromecast/public/graphics_types.h" | 12 #include "chromecast/public/graphics_types.h" |
12 #include "chromecast/public/video_plane.h" | 13 #include "chromecast/public/video_plane.h" |
13 #include "ui/ozone/ozone_export.h" | 14 #include "ui/ozone/ozone_export.h" |
14 #include "ui/ozone/public/overlay_manager_ozone.h" | 15 #include "ui/ozone/public/overlay_manager_ozone.h" |
15 | 16 |
16 namespace ui { | 17 namespace ui { |
17 | 18 |
18 class OZONE_EXPORT OverlayManagerCast : public OverlayManagerOzone { | 19 class OZONE_EXPORT OverlayManagerCast : public OverlayManagerOzone { |
19 public: | 20 public: |
20 OverlayManagerCast(); | 21 OverlayManagerCast(); |
21 ~OverlayManagerCast() override; | 22 ~OverlayManagerCast() override; |
22 | 23 |
23 // OverlayManagerOzone: | 24 // OverlayManagerOzone: |
24 scoped_ptr<OverlayCandidatesOzone> CreateOverlayCandidates( | 25 std::unique_ptr<OverlayCandidatesOzone> CreateOverlayCandidates( |
25 gfx::AcceleratedWidget w) override; | 26 gfx::AcceleratedWidget w) override; |
26 | 27 |
27 // Callback that's made whenever an overlay quad is processed | 28 // Callback that's made whenever an overlay quad is processed |
28 // in the compositor. Used to allow hardware video plane to | 29 // in the compositor. Used to allow hardware video plane to |
29 // be positioned to match compositor hole. | 30 // be positioned to match compositor hole. |
30 using OverlayCompositedCallback = | 31 using OverlayCompositedCallback = |
31 base::Callback<void(const chromecast::RectF&, | 32 base::Callback<void(const chromecast::RectF&, |
32 chromecast::media::VideoPlane::Transform)>; | 33 chromecast::media::VideoPlane::Transform)>; |
33 static void SetOverlayCompositedCallback(const OverlayCompositedCallback& cb); | 34 static void SetOverlayCompositedCallback(const OverlayCompositedCallback& cb); |
34 | 35 |
35 private: | 36 private: |
36 | 37 |
37 DISALLOW_COPY_AND_ASSIGN(OverlayManagerCast); | 38 DISALLOW_COPY_AND_ASSIGN(OverlayManagerCast); |
38 }; | 39 }; |
39 | 40 |
40 } // namespace ui | 41 } // namespace ui |
41 | 42 |
42 #endif // UI_OZONE_PLATFORM_CAST_OVERLAY_MANAGER_CAST_H_ | 43 #endif // UI_OZONE_PLATFORM_CAST_OVERLAY_MANAGER_CAST_H_ |
OLD | NEW |