summaryrefslogtreecommitdiffstats
path: root/sdm
diff options
context:
space:
mode:
authorSushil Chauhan <sushilchauhan@codeaurora.org>2018-03-19 11:19:27 -0700
committerGurpreet Singh Dhami <gdhami@codeaurora.org>2018-05-08 18:06:56 -0400
commitf64972e0fa82c808f4dc75b3824d7974153238ca (patch)
treec47e46707ded294ab816542e78e7457913626a49 /sdm
parent76848f2db0390cd1b653afe052bcb8554cb1a0d3 (diff)
downloadandroid_hardware_qcom_sdm710_display-f64972e0fa82c808f4dc75b3824d7974153238ca.tar.gz
android_hardware_qcom_sdm710_display-f64972e0fa82c808f4dc75b3824d7974153238ca.tar.bz2
android_hardware_qcom_sdm710_display-f64972e0fa82c808f4dc75b3824d7974153238ca.zip
hwc2: Add HLG cap in the HDR capabilities
Add HAL_HDR_HLG in the HDR Capabilities of HWC device implementation. CRs-Fixed: 2209117 Change-Id: I64ea9c5f4dfe3f1eb8176906016242acbb2251e8
Diffstat (limited to 'sdm')
-rw-r--r--sdm/libs/hwc2/hwc_display.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/sdm/libs/hwc2/hwc_display.cpp b/sdm/libs/hwc2/hwc_display.cpp
index 3b228b88..28a2a5ef 100644
--- a/sdm/libs/hwc2/hwc_display.cpp
+++ b/sdm/libs/hwc2/hwc_display.cpp
@@ -1234,11 +1234,12 @@ HWC2::Error HWCDisplay::GetHdrCapabilities(uint32_t *out_num_types, int32_t *out
}
if (out_types == nullptr) {
- // 1(now) - because we support only HDR10, change when HLG & DOLBY vision are supported
- *out_num_types = 1;
+ // We support HDR10 and HLG
+ *out_num_types = 2;
} else {
- // Only HDR10 supported
- *out_types = HAL_HDR_HDR10;
+ // HDR10 and HLG are supported
+ out_types[0] = HAL_HDR_HDR10;
+ out_types[1] = HAL_HDR_HLG;
static const float kLuminanceFactor = 10000.0;
// luminance is expressed in the unit of 0.0001 cd/m2, convert it to 1cd/m2.
*out_max_luminance = FLOAT(fixed_info.max_luminance)/kLuminanceFactor;