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

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

Issue 2613493002: Fix namespace for src/ui/display/. (Closed)
Patch Set: Rebase. Created 3 years, 11 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 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_DRM_HOST_DRM_DISPLAY_HOST_H_ 5 #ifndef UI_OZONE_PLATFORM_DRM_HOST_DRM_DISPLAY_HOST_H_
6 #define UI_OZONE_PLATFORM_DRM_HOST_DRM_DISPLAY_HOST_H_ 6 #define UI_OZONE_PLATFORM_DRM_HOST_DRM_DISPLAY_HOST_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "ui/display/types/display_constants.h" 11 #include "ui/display/types/display_constants.h"
12 #include "ui/display/types/native_display_delegate.h" 12 #include "ui/display/types/native_display_delegate.h"
13 #include "ui/ozone/platform/drm/host/gpu_thread_observer.h" 13 #include "ui/ozone/platform/drm/host/gpu_thread_observer.h"
14 14
15 namespace display {
16 class DisplaySnapshot;
17 }
18
15 namespace ui { 19 namespace ui {
16 20
17 struct DisplaySnapshot_Params; 21 struct DisplaySnapshot_Params;
18 class DisplaySnapshot;
19 class GpuThreadAdapter; 22 class GpuThreadAdapter;
20 23
21 class DrmDisplayHost : public GpuThreadObserver { 24 class DrmDisplayHost : public GpuThreadObserver {
22 public: 25 public:
23 DrmDisplayHost(GpuThreadAdapter* sender, 26 DrmDisplayHost(GpuThreadAdapter* sender,
24 const DisplaySnapshot_Params& params, 27 const DisplaySnapshot_Params& params,
25 bool is_dummy); 28 bool is_dummy);
26 ~DrmDisplayHost() override; 29 ~DrmDisplayHost() override;
27 30
28 DisplaySnapshot* snapshot() const { return snapshot_.get(); } 31 display::DisplaySnapshot* snapshot() const { return snapshot_.get(); }
29 32
30 void UpdateDisplaySnapshot(const DisplaySnapshot_Params& params); 33 void UpdateDisplaySnapshot(const DisplaySnapshot_Params& params);
31 void Configure(const DisplayMode* mode, 34 void Configure(const display::DisplayMode* mode,
32 const gfx::Point& origin, 35 const gfx::Point& origin,
33 const ConfigureCallback& callback); 36 const display::ConfigureCallback& callback);
34 void GetHDCPState(const GetHDCPStateCallback& callback); 37 void GetHDCPState(const display::GetHDCPStateCallback& callback);
35 void SetHDCPState(HDCPState state, const SetHDCPStateCallback& callback); 38 void SetHDCPState(display::HDCPState state,
36 void SetColorCorrection(const std::vector<GammaRampRGBEntry>& degamma_lut, 39 const display::SetHDCPStateCallback& callback);
37 const std::vector<GammaRampRGBEntry>& gamma_lut, 40 void SetColorCorrection(
38 const std::vector<float>& correction_matrix); 41 const std::vector<display::GammaRampRGBEntry>& degamma_lut,
42 const std::vector<display::GammaRampRGBEntry>& gamma_lut,
43 const std::vector<float>& correction_matrix);
39 44
40 // Called when the IPC from the GPU process arrives to answer the above 45 // Called when the IPC from the GPU process arrives to answer the above
41 // commands. 46 // commands.
42 void OnDisplayConfigured(bool status); 47 void OnDisplayConfigured(bool status);
43 void OnHDCPStateReceived(bool status, HDCPState state); 48 void OnHDCPStateReceived(bool status, display::HDCPState state);
44 void OnHDCPStateUpdated(bool status); 49 void OnHDCPStateUpdated(bool status);
45 50
46 // GpuThreadObserver: 51 // GpuThreadObserver:
47 void OnGpuProcessLaunched() override; 52 void OnGpuProcessLaunched() override;
48 void OnGpuThreadReady() override; 53 void OnGpuThreadReady() override;
49 void OnGpuThreadRetired() override; 54 void OnGpuThreadRetired() override;
50 55
51 private: 56 private:
52 // Calls all the callbacks with failure. 57 // Calls all the callbacks with failure.
53 void ClearCallbacks(); 58 void ClearCallbacks();
54 59
55 GpuThreadAdapter* sender_; // Not owned. 60 GpuThreadAdapter* sender_; // Not owned.
56 61
57 std::unique_ptr<DisplaySnapshot> snapshot_; 62 std::unique_ptr<display::DisplaySnapshot> snapshot_;
58 63
59 // Used during startup to signify that any display configuration should be 64 // Used during startup to signify that any display configuration should be
60 // synchronous and succeed. 65 // synchronous and succeed.
61 bool is_dummy_; 66 bool is_dummy_;
62 67
63 ConfigureCallback configure_callback_; 68 display::ConfigureCallback configure_callback_;
64 GetHDCPStateCallback get_hdcp_callback_; 69 display::GetHDCPStateCallback get_hdcp_callback_;
65 SetHDCPStateCallback set_hdcp_callback_; 70 display::SetHDCPStateCallback set_hdcp_callback_;
66 71
67 DISALLOW_COPY_AND_ASSIGN(DrmDisplayHost); 72 DISALLOW_COPY_AND_ASSIGN(DrmDisplayHost);
68 }; 73 };
69 74
70 } // namespace ui 75 } // namespace ui
71 76
72 #endif // UI_OZONE_PLATFORM_DRM_HOST_DRM_DISPLAY_HOST_H_ 77 #endif // UI_OZONE_PLATFORM_DRM_HOST_DRM_DISPLAY_HOST_H_
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/gpu/screen_manager.cc ('k') | ui/ozone/platform/drm/host/drm_display_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698