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

Side by Side Diff: ui/ozone/platform/dri/hardware_display_plane_manager.h

Issue 886323004: ozone: dri: Fix undefined references in DRI platform GN build (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: also fix gyp build Created 5 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_ 5 #ifndef UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_
6 #define UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_ 6 #define UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 #include <xf86drmMode.h> 10 #include <xf86drmMode.h>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/basictypes.h" 13 #include "base/basictypes.h"
14 #include "base/memory/scoped_vector.h" 14 #include "base/memory/scoped_vector.h"
15 #include "ui/ozone/ozone_export.h"
15 #include "ui/ozone/platform/dri/hardware_display_plane.h" 16 #include "ui/ozone/platform/dri/hardware_display_plane.h"
16 #include "ui/ozone/platform/dri/overlay_plane.h" 17 #include "ui/ozone/platform/dri/overlay_plane.h"
17 #include "ui/ozone/platform/dri/scoped_drm_types.h" 18 #include "ui/ozone/platform/dri/scoped_drm_types.h"
18 19
19 namespace gfx { 20 namespace gfx {
20 class Rect; 21 class Rect;
21 } // namespace gfx 22 } // namespace gfx
22 23
23 namespace ui { 24 namespace ui {
24 25
25 class DriWrapper; 26 class DriWrapper;
26 class CrtcController; 27 class CrtcController;
27 28
28 // This contains the list of planes controlled by one HDC on a given DRM fd. 29 // This contains the list of planes controlled by one HDC on a given DRM fd.
29 // It is owned by the HDC and filled by the CrtcController. 30 // It is owned by the HDC and filled by the CrtcController.
30 struct HardwareDisplayPlaneList { 31 struct OZONE_EXPORT HardwareDisplayPlaneList {
31 HardwareDisplayPlaneList(); 32 HardwareDisplayPlaneList();
32 ~HardwareDisplayPlaneList(); 33 ~HardwareDisplayPlaneList();
33 34
34 // This is the list of planes to be committed this time. 35 // This is the list of planes to be committed this time.
35 std::vector<HardwareDisplayPlane*> plane_list; 36 std::vector<HardwareDisplayPlane*> plane_list;
36 // This is the list of planes that was committed last time. 37 // This is the list of planes that was committed last time.
37 std::vector<HardwareDisplayPlane*> old_plane_list; 38 std::vector<HardwareDisplayPlane*> old_plane_list;
38 39
39 struct PageFlipInfo { 40 struct PageFlipInfo {
40 PageFlipInfo(uint32_t crtc_id, 41 PageFlipInfo(uint32_t crtc_id,
(...skipping 21 matching lines...) Expand all
62 std::vector<Plane> planes; 63 std::vector<Plane> planes;
63 }; 64 };
64 // In the case of non-atomic operation, this info will be used for 65 // In the case of non-atomic operation, this info will be used for
65 // pageflipping. 66 // pageflipping.
66 std::vector<PageFlipInfo> legacy_page_flips; 67 std::vector<PageFlipInfo> legacy_page_flips;
67 68
68 // Set if the last operation on this list was a Commit(). 69 // Set if the last operation on this list was a Commit().
69 bool committed; 70 bool committed;
70 }; 71 };
71 72
72 class HardwareDisplayPlaneManager { 73 class OZONE_EXPORT HardwareDisplayPlaneManager {
73 public: 74 public:
74 HardwareDisplayPlaneManager(); 75 HardwareDisplayPlaneManager();
75 virtual ~HardwareDisplayPlaneManager(); 76 virtual ~HardwareDisplayPlaneManager();
76 77
77 // This parses information from the drm driver, adding any new planes 78 // This parses information from the drm driver, adding any new planes
78 // or crtcs found. 79 // or crtcs found.
79 bool Initialize(DriWrapper* drm); 80 bool Initialize(DriWrapper* drm);
80 81
81 // Assign hardware planes from the |planes_| list to |overlay_list| entries, 82 // Assign hardware planes from the |planes_| list to |overlay_list| entries,
82 // recording the plane IDs in the |plane_list|. Only planes compatible with 83 // recording the plane IDs in the |plane_list|. Only planes compatible with
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 116
116 ScopedVector<HardwareDisplayPlane> planes_; 117 ScopedVector<HardwareDisplayPlane> planes_;
117 std::vector<uint32_t> crtcs_; 118 std::vector<uint32_t> crtcs_;
118 119
119 DISALLOW_COPY_AND_ASSIGN(HardwareDisplayPlaneManager); 120 DISALLOW_COPY_AND_ASSIGN(HardwareDisplayPlaneManager);
120 }; 121 };
121 122
122 } // namespace ui 123 } // namespace ui
123 124
124 #endif // UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_ 125 #endif // UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_
OLDNEW
« no previous file with comments | « ui/ozone/platform/dri/hardware_display_plane.h ('k') | ui/ozone/platform/dri/hardware_display_plane_manager_legacy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698