| OLD | NEW |
| 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> |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 | 81 |
| 82 // Assign hardware planes from the |planes_| list to |overlay_list| entries, | 82 // Assign hardware planes from the |planes_| list to |overlay_list| entries, |
| 83 // 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 |
| 84 // |crtc_id| will be used. |overlay_list| must be sorted bottom-to-top. | 84 // |crtc_id| will be used. |overlay_list| must be sorted bottom-to-top. |
| 85 virtual bool AssignOverlayPlanes(HardwareDisplayPlaneList* plane_list, | 85 virtual bool AssignOverlayPlanes(HardwareDisplayPlaneList* plane_list, |
| 86 const OverlayPlaneList& overlay_list, | 86 const OverlayPlaneList& overlay_list, |
| 87 uint32_t crtc_id, | 87 uint32_t crtc_id, |
| 88 CrtcController* crtc); | 88 CrtcController* crtc); |
| 89 | 89 |
| 90 // Commit the plane states in |plane_list|. | 90 // Commit the plane states in |plane_list|. |
| 91 virtual bool Commit(HardwareDisplayPlaneList* plane_list) = 0; | 91 virtual bool Commit(HardwareDisplayPlaneList* plane_list, bool is_sync) = 0; |
| 92 | 92 |
| 93 // Set all planes in |plane_list| owned by |crtc_id| to free. | 93 // Set all planes in |plane_list| owned by |crtc_id| to free. |
| 94 static void ResetPlanes(HardwareDisplayPlaneList* plane_list, | 94 static void ResetPlanes(HardwareDisplayPlaneList* plane_list, |
| 95 uint32_t crtc_id); | 95 uint32_t crtc_id); |
| 96 | 96 |
| 97 const ScopedVector<HardwareDisplayPlane>& planes() { return planes_; } | 97 const ScopedVector<HardwareDisplayPlane>& planes() { return planes_; } |
| 98 | 98 |
| 99 protected: | 99 protected: |
| 100 virtual bool SetPlaneData(HardwareDisplayPlaneList* plane_list, | 100 virtual bool SetPlaneData(HardwareDisplayPlaneList* plane_list, |
| 101 HardwareDisplayPlane* hw_plane, | 101 HardwareDisplayPlane* hw_plane, |
| (...skipping 14 matching lines...) Expand all Loading... |
| 116 | 116 |
| 117 ScopedVector<HardwareDisplayPlane> planes_; | 117 ScopedVector<HardwareDisplayPlane> planes_; |
| 118 std::vector<uint32_t> crtcs_; | 118 std::vector<uint32_t> crtcs_; |
| 119 | 119 |
| 120 DISALLOW_COPY_AND_ASSIGN(HardwareDisplayPlaneManager); | 120 DISALLOW_COPY_AND_ASSIGN(HardwareDisplayPlaneManager); |
| 121 }; | 121 }; |
| 122 | 122 |
| 123 } // namespace ui | 123 } // namespace ui |
| 124 | 124 |
| 125 #endif // UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_ | 125 #endif // UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_MANAGER_H_ |
| OLD | NEW |