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
3 // found in the LICENSE file.
5 #ifndef UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_H_
6 #define UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_H_
11 #include "base/basictypes.h"
12 #include "ui/ozone/platform/dri/scoped_drm_types.h"
22 class HardwareDisplayPlane
{
24 HardwareDisplayPlane(ScopedDrmPlanePtr plane
);
25 HardwareDisplayPlane(uint32_t plane_id
, uint32_t possible_crtcs
);
27 virtual ~HardwareDisplayPlane();
29 bool Initialize(DriWrapper
* drm
);
31 bool CanUseForCrtc(uint32_t crtc_index
);
33 bool in_use() const { return in_use_
; }
34 void set_in_use(bool in_use
) { in_use_
= in_use
; }
36 uint32_t plane_id() const { return plane_id_
; }
38 void set_owning_crtc(uint32_t crtc
) { owning_crtc_
= crtc
; }
39 uint32_t owning_crtc() const { return owning_crtc_
; }
43 uint32_t possible_crtcs_
;
44 uint32_t owning_crtc_
;
47 DISALLOW_COPY_AND_ASSIGN(HardwareDisplayPlane
);
52 #endif // UI_OZONE_PLATFORM_DRI_HARDWARE_DISPLAY_PLANE_H_