Merge tag 'LA.UM.10.6.2.r1-02500-89xx.0' into int/13/fp3
"LA.UM.10.6.2.r1-02500-89xx.0"
* tag 'LA.UM.10.6.2.r1-02500-89xx.0':
display: Add client interface for DisplayConfig APIs
Change-Id: I585e7be2d766b5751fb2ab379e324dacd65072ae
diff --git a/services/config/config_defs.h b/services/config/config_defs.h
index 5572d63..fe316da 100644
--- a/services/config/config_defs.h
+++ b/services/config/config_defs.h
@@ -27,6 +27,42 @@
* IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+/*
+ * Changes from Qualcomm Innovation Center are provided under the following license:
+ *
+ * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted (subject to the limitations in the
+ * disclaimer below) provided that the following conditions are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following
+ * disclaimer in the documentation and/or other materials provided
+ * with the distribution.
+ *
+ * * Neither the name of Qualcomm Innovation Center, Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE
+ * GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT
+ * HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
+ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
+ * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+ * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+ * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+ * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
#ifndef __CONFIG_DEFS_H__
#define __CONFIG_DEFS_H__
@@ -111,6 +147,16 @@
kOn,
};
+enum class RGBOrder : int {
+ kFSCUnknown = 0,
+ kFSCRGB = 1,
+ kFSCRBG = 2,
+ kFSCBGR = 3,
+ kFSCBRG = 4,
+ kFSCGBR = 5,
+ kFSCGRB = 6,
+};
+
// Input and Output Params structures
struct Attributes {
uint32_t vsync_period = 0;
@@ -280,6 +326,41 @@
uint32_t fps = 0;
};
+struct EnableCACParams {
+ uint32_t disp_id = 0;
+ bool enable = 0;
+ float red = 0;
+ float green = 0;
+ float blue = 0;
+};
+
+struct CacChannelRect {
+ float left = 0;
+ float top = 0;
+ float right = 0;
+ float bottom = 0;
+};
+
+struct CacEyeConfig {
+ CacChannelRect red_channel_src = {};
+ CacChannelRect red_channel_dst = {};
+ CacChannelRect green_channel_src = {};
+ CacChannelRect green_channel_dst = {};
+ CacChannelRect blue_channel_src = {};
+ CacChannelRect blue_channel_dst = {};
+};
+
+struct CacEyeConfigParams {
+ uint32_t disp_id = 0;
+ CacEyeConfig left = {};
+ CacEyeConfig right = {};
+};
+
+struct SkewVsyncParams {
+ uint32_t disp_id = 0;
+ uint32_t skew_vsync_val = 0;
+};
+
/* Callback Interface */
class ConfigCallback {
public:
@@ -380,6 +461,13 @@
WiderModePref /* mode_pref */) DEFAULT_RET
virtual int ControlCameraSmoothCallback(bool /* enable */) DEFAULT_RET
virtual int DummyDisplayConfigAPI() DEFAULT_RET
+ virtual int GetFSCRGBOrder(DisplayType /* dpy */,
+ RGBOrder* /* fsc_rgb_color_order */) DEFAULT_RET
+ virtual int EnableCAC(uint32_t /* disp_id */, bool /* enable */, float /* red */,
+ float /* green */, float /* blue */) DEFAULT_RET
+ virtual int SetCacEyeConfig(uint32_t /* disp_id */, const CacEyeConfig & /* left */,
+ const CacEyeConfig & /* right */) DEFAULT_RET
+ virtual int SetSkewVsync(uint32_t /* disp_id */, uint32_t /* skew_vsync_val */) DEFAULT_RET
// deprecated APIs
virtual int GetDebugProperty(const std::string /* prop_name */,