Add generic API for Set/GetColorMode and move HWC2 specific behavior to
hwc2_device.
Remove HwcDisplay::SetColorModeWithIntent, as the only supported intent
is colormetric.
Rename Colormode to ColorMode.
Fix contract between color mode and render intent. All supported color
modes should have a supported render intent (COLORMETRIC at least).
Change-Id: Ic1002b630f925e1ea75cb6ad7822b1384010143e
Signed-off-by: Sasha McIntosh <sashamcintosh@google.com>
These were only used in the legacy GetDisplayAttribute, which is now
moved to the HWC2 frontend and implemented in the same way as the HWC3
frontend, which uses GetBoundsMm.
Change-Id: I841a8da7763a72c8a8956cd7daf1393c61f5e587
Signed-off-by: Drew Davenport <ddavenport@google.com>
Remove const qualifiers from luminance data variables.
Set an empty HDR_OUTPUT_METADATA blob to ensure the property is
cleared when switching color modes.
Change-Id: I15d1477a98a1f4e103ef0202c157b8dfb5af8f86
Signed-off-by: Sasha McIntosh <sashamcintosh@google.com>
Edid are not the most reliable when it comes to panel size, however it
seems like preferred DTD are slightly more reliable. This change moves
from the drm parse edid display size to the first preferred DTD to try
improve dpi accuracy.
If no preferred DTD is available we still fallback to the display size.
Change-Id: Ibcc95da9f38ba74e9b95b9d68587b38efbed8de2
signed-off-by: Lucas Berthou <berlu@google.com>
Retrieve color and HDR information from the EDID.
Change-Id: I1aac27644d5c4fd5d5f295ca32b69ed69e94e0c6
Signed-off-by: Sasha McIntosh <sashamcintosh@google.com>
Implement a function to set HDR metadata on the connector. Support HDR10
and HLG, which are common HDR types.
Change-Id: Id3dbe8eea2ee6b8ba700af23845a43e2070dd14e
Signed-off-by: Sasha McIntosh <sashamcintosh@google.com>