aboutsummaryrefslogtreecommitdiff
path: root/drmproperty.cpp
diff options
context:
space:
mode:
authorAlexandru Gheorghe <alexandru-cosmin.gheorghe@arm.com>2018-09-17 10:48:54 +0100
committerAlexandru Gheorghe <alexandru-cosmin.gheorghe@arm.com>2018-10-09 17:05:09 +0100
commitea1c5e5a1bd4830b7c8b8da230e816e5efda1acb (patch)
tree0280feb109d9403474c386fe8d073852ecacbb0b /drmproperty.cpp
parent2234d3770463adca2be1a8bd9496c28e50bb3dd1 (diff)
downloaddrm_hwcomposer-ea1c5e5a1bd4830b7c8b8da230e816e5efda1acb.tar.gz
drm_hwcomposer: Add z order support
Currently, the planner just pops the first available drm plane and if that can't be used for the DrmHwcLayer it just returns error. This proposes a slighlty smarter way to do that by trying to see if any of the DrmPlane can be used for the DrmHwcLayer in question. More, if the drm_plane doesn't have a fix zorder then we could re-add him to the list of unused planes, so it could be used for hosting other less demanding DrmHwcLayers. Signed-off-by: Alexandru Gheorghe <alexandru-cosmin.gheorghe@arm.com>
Diffstat (limited to 'drmproperty.cpp')
-rw-r--r--drmproperty.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/drmproperty.cpp b/drmproperty.cpp
index dcab05e..9faa37e 100644
--- a/drmproperty.cpp
+++ b/drmproperty.cpp
@@ -100,6 +100,10 @@ int DrmProperty::value(uint64_t *value) const {
}
}
+bool DrmProperty::immutable() const {
+ return id_ && (flags_ & DRM_MODE_PROP_IMMUTABLE);
+}
+
std::tuple<uint64_t, int> DrmProperty::GetEnumValueWithName(
std::string name) const {
for (auto it : enums_) {