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

Side by Side Diff: ui/ozone/platform/drm/host/drm_overlay_candidates_host.h

Issue 1661783002: Centralize all gbm ozone host IPC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments Created 4 years, 10 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 2015 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 UI_OZONE_PLATFORM_DRM_HOST_OVERLAY_CANDIDATES_H_ 5 #ifndef UI_OZONE_PLATFORM_DRM_HOST_DRM_OVERLAY_CANDIDATES_HOST_H_
6 #define UI_OZONE_PLATFORM_DRM_HOST_OVERLAY_CANDIDATES_H_ 6 #define UI_OZONE_PLATFORM_DRM_HOST_DRM_OVERLAY_CANDIDATES_HOST_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <deque>
11 #include <map>
10 #include <vector> 12 #include <vector>
11 13
14 #include "base/containers/mru_cache.h"
12 #include "base/macros.h" 15 #include "base/macros.h"
16 #include "ui/ozone/platform/drm/host/gpu_thread_adapter.h"
17 #include "ui/ozone/platform/drm/host/gpu_thread_observer.h"
13 #include "ui/ozone/public/overlay_candidates_ozone.h" 18 #include "ui/ozone/public/overlay_candidates_ozone.h"
14 19
15 namespace ui { 20 namespace ui {
16 21
17 class DrmOverlayManagerCore; 22 class DrmOverlayManager;
18 23
19 // This is an implementation of OverlayCandidatesOzone where the driver is asked 24 // This is an implementation of OverlayCandidatesOzone where the driver is asked
20 // about overlay capabilities via IPC. We have no way of querying abstract 25 // about overlay capabilities via IPC. We have no way of querying abstract
21 // capabilities, only if a particular configuration is supported or not. 26 // capabilities, only if a particular configuration is supported or not.
22 // Each time we we are asked if a particular configuration is supported, if we 27 // Each time we we are asked if a particular configuration is supported, if we
23 // have not seen that configuration before, it is IPCed to the GPU via 28 // have not seen that configuration before, it is IPCed to the GPU via
24 // OzoneGpuMsg_CheckOverlayCapabilities; a test commit is then performed and 29 // OzoneGpuMsg_CheckOverlayCapabilities; a test commit is then performed and
25 // the result is returned in OzoneHostMsg_OverlayCapabilitiesReceived. Testing 30 // the result is returned in OzoneHostMsg_OverlayCapabilitiesReceived. Testing
26 // is asynchronous, until the reply arrives that configuration will be failed. 31 // is asynchronous, until the reply arrives that configuration will be failed.
27 // 32 //
28 // All OverlayCandidatesOzone objects share a single cache of tested 33 // All OverlayCandidatesOzone objects share a single cache of tested
29 // configurations stored in the overlay manager. 34 // configurations stored in the overlay manager.
30 class DrmOverlayCandidatesHost : public OverlayCandidatesOzone { 35 class DrmOverlayCandidatesHost : public OverlayCandidatesOzone {
31 public: 36 public:
32 DrmOverlayCandidatesHost(DrmOverlayManagerCore* manager_core, 37 DrmOverlayCandidatesHost(DrmOverlayManager* manager_core,
33 gfx::AcceleratedWidget widget); 38 gfx::AcceleratedWidget widget);
34 ~DrmOverlayCandidatesHost() override; 39 ~DrmOverlayCandidatesHost() override;
35 40
36 void CheckOverlaySupport(OverlaySurfaceCandidateList* candidates) override; 41 void CheckOverlaySupport(OverlaySurfaceCandidateList* candidates) override;
37 42
38 private: 43 private:
39 DrmOverlayManagerCore* overlay_manager_; // Not owned. 44 DrmOverlayManager* overlay_manager_; // Not owned.
40 gfx::AcceleratedWidget widget_; 45 gfx::AcceleratedWidget widget_;
41 46
42 DISALLOW_COPY_AND_ASSIGN(DrmOverlayCandidatesHost); 47 DISALLOW_COPY_AND_ASSIGN(DrmOverlayCandidatesHost);
43 }; 48 };
44 49
45 } // namespace ui 50 } // namespace ui
46 51
47 #endif // UI_OZONE_PLATFORM_DRM_HOST_OVERLAY_CANDIDATES_H_ 52 #endif // UI_OZONE_PLATFORM_DRM_HOST_DRM_OVERLAY_CANDIDATES_HOST_H_
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/host/drm_gpu_platform_support_host.cc ('k') | ui/ozone/platform/drm/host/drm_overlay_candidates_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698