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

Side by Side Diff: ui/ozone/platform/drm/host/gpu_thread_adapter.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
« no previous file with comments | « ui/ozone/platform/drm/host/drm_window_host.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef UI_OZONE_PLATFORM_DRM_HOST_GPU_THREAD_ADAPTER_H_
6 #define UI_OZONE_PLATFORM_DRM_HOST_GPU_THREAD_ADAPTER_H_
7
8 #include "base/file_descriptor_posix.h"
9 #include "ui/display/types/display_constants.h"
10 #include "ui/display/types/gamma_ramp_rgb_entry.h"
11 #include "ui/ozone/common/gpu/ozone_gpu_message_params.h"
12 #include "ui/ozone/public/overlay_candidates_ozone.h"
13
14 namespace ui {
15
16 class DrmDisplayHostManager;
17 class DrmOverlayManager;
18 class GpuThreadObserver;
19
20 // Provides the services that the various host components need
21 // to use either a GPU process or thread for their implementation.
22 class GpuThreadAdapter {
23 public:
24 virtual ~GpuThreadAdapter() {}
25
26 virtual bool IsConnected() = 0;
27 virtual void AddGpuThreadObserver(GpuThreadObserver* observer) = 0;
28 virtual void RemoveGpuThreadObserver(GpuThreadObserver* observer) = 0;
29
30 // Methods for Display management.
31 virtual void RegisterHandlerForDrmDisplayHostManager(
32 DrmDisplayHostManager* handler) = 0;
33 virtual void UnRegisterHandlerForDrmDisplayHostManager() = 0;
34
35 // Services needed for DrmDisplayHostMananger
36 virtual bool GpuTakeDisplayControl() = 0;
37 virtual bool GpuRefreshNativeDisplays() = 0;
38 virtual bool GpuRelinquishDisplayControl() = 0;
39 virtual bool GpuAddGraphicsDevice(const base::FilePath& path,
40 base::FileDescriptor fd) = 0;
41 virtual bool GpuRemoveGraphicsDevice(const base::FilePath& path) = 0;
42
43 // Methods for DrmOverlayManager.
44 virtual void RegisterHandlerForDrmOverlayManager(
45 DrmOverlayManager* handler) = 0;
46 virtual void UnRegisterHandlerForDrmOverlayManager() = 0;
47
48 // Services needed by DrmOverlayManager
49 virtual bool GpuCheckOverlayCapabilities(
50 gfx::AcceleratedWidget widget,
51 const std::vector<OverlayCheck_Params>& new_params) = 0;
52
53 // Services needed by DrmDisplayHost
54 virtual bool GpuConfigureNativeDisplay(int64_t display_id,
55 ui::DisplayMode_Params display_mode,
56 gfx::Point point) = 0;
57 virtual bool GpuDisableNativeDisplay(int64_t display_id) = 0;
58 virtual bool GpuGetHDCPState(int64_t display_id) = 0;
59 virtual bool GpuSetHDCPState(int64_t display_id, ui::HDCPState state) = 0;
60 virtual bool GpuSetGammaRamp(int64_t display_id,
61 const std::vector<GammaRampRGBEntry>& lut) = 0;
62
63 // Services needed by DrmWindowHost
64 virtual bool GpuDestroyWindow(gfx::AcceleratedWidget widget) = 0;
65 virtual bool GpuCreateWindow(gfx::AcceleratedWidget widget) = 0;
66 virtual bool GpuWindowBoundsChanged(gfx::AcceleratedWidget widget,
67 gfx::Rect bounds) = 0;
68 };
69
70 } // namespace ui
71
72 #endif // UI_OZONE_PLATFORM_DRM_HOST_GPU_THREAD_ADAPTER_H_
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/host/drm_window_host.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698