Add additional picture parameter

Test: m on cuttlefish
Flag: android.media.tv.flags.media_quality_fw
Bug: 375472716

Change-Id: I2b314ed7cade4bf7458e1f47ffd64790d27e5f05
diff --git a/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/ColorTemperature.aidl b/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/ColorTemperature.aidl
new file mode 100644
index 0000000..2d26aca
--- /dev/null
+++ b/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/ColorTemperature.aidl
@@ -0,0 +1,47 @@
+/*
+ * Copyright (C) 2024 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+///////////////////////////////////////////////////////////////////////////////
+// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE.                          //
+///////////////////////////////////////////////////////////////////////////////
+
+// This file is a snapshot of an AIDL file. Do not edit it manually. There are
+// two cases:
+// 1). this is a frozen version file - do not edit this in any case.
+// 2). this is a 'current' file. If you make a backwards compatible change to
+//     the interface (from the latest frozen version), the build system will
+//     prompt you to update this file with `m <name>-update-api`.
+//
+// You must not make a backward incompatible change to any AIDL file built
+// with the aidl_interface module type with versions property set. The module
+// type is used to build AIDL files in a way that they can be used across
+// independently updatable components of the system. If a device is shipped
+// with such a backward incompatible change, it has a high risk of breaking
+// later when a module using the interface is updated, e.g., Mainline modules.
+
+package android.hardware.tv.mediaquality;
+@VintfStability
+enum ColorTemperature {
+  USER,
+  COOL,
+  STANDARD,
+  WARM,
+  USER_HDR10PLUS,
+  COOL_HDR10PLUS,
+  STANDARD_HDR10PLUS,
+  WARM_HDR10PLUS,
+  FMMSDR,
+  FMMHDR,
+}
diff --git a/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/PictureParameter.aidl b/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/PictureParameter.aidl
index 134997b..ae396ad 100644
--- a/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/PictureParameter.aidl
+++ b/tv/mediaquality/aidl/aidl_api/android.hardware.tv.mediaquality/current/android/hardware/tv/mediaquality/PictureParameter.aidl
@@ -39,4 +39,25 @@
   int sharpness;
   int saturation;
   int hue;
+  int colorTunerBrightness;
+  int colorTunerSaturation;
+  int colorTunerHue;
+  int colorTunerRedOffset;
+  int colorTunerGreenOffset;
+  int colorTunerBlueOffset;
+  int colorTunerRedGain;
+  int colorTunerGreenGain;
+  int colorTunerBlueGain;
+  android.hardware.tv.mediaquality.QualityLevel noiseReduction;
+  android.hardware.tv.mediaquality.QualityLevel mpegNoiseReduction;
+  android.hardware.tv.mediaquality.QualityLevel fleshTone;
+  android.hardware.tv.mediaquality.QualityLevel deContour;
+  android.hardware.tv.mediaquality.QualityLevel dynamicLumaControl;
+  boolean filmMode;
+  boolean blueStretch;
+  boolean colorTune;
+  android.hardware.tv.mediaquality.ColorTemperature colorTemperature;
+  boolean globeDimming;
+  boolean autoPictureQualityEnabled;
+  boolean autoSuperResolutionEnabled;
 }
diff --git a/tv/mediaquality/aidl/android/hardware/tv/mediaquality/ColorTemperature.aidl b/tv/mediaquality/aidl/android/hardware/tv/mediaquality/ColorTemperature.aidl
new file mode 100644
index 0000000..4d4b01c
--- /dev/null
+++ b/tv/mediaquality/aidl/android/hardware/tv/mediaquality/ColorTemperature.aidl
@@ -0,0 +1,31 @@
+/*
+ * Copyright (C) 2024 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.hardware.tv.mediaquality;
+
+@VintfStability
+enum ColorTemperature {
+    USER,
+    COOL,
+    STANDARD,
+    WARM,
+    USER_HDR10PLUS,
+    COOL_HDR10PLUS,
+    STANDARD_HDR10PLUS,
+    WARM_HDR10PLUS,
+    FMMSDR,
+    FMMHDR,
+}
diff --git a/tv/mediaquality/aidl/android/hardware/tv/mediaquality/PictureParameter.aidl b/tv/mediaquality/aidl/android/hardware/tv/mediaquality/PictureParameter.aidl
index 342b593..922368d 100644
--- a/tv/mediaquality/aidl/android/hardware/tv/mediaquality/PictureParameter.aidl
+++ b/tv/mediaquality/aidl/android/hardware/tv/mediaquality/PictureParameter.aidl
@@ -16,6 +16,8 @@
 
 package android.hardware.tv.mediaquality;
 
+import android.hardware.tv.mediaquality.ColorTemperature;
+import android.hardware.tv.mediaquality.QualityLevel;
 /**
  * The parameters for Picture Profile.
  */
@@ -62,4 +64,127 @@
      * The default/unmodified value for hue is 0.
      */
     int hue;
+
+    /*
+     * Adjust brightness in advance color engine. Similar to a "brightness" control on a TV
+     * but acts at a lower level.
+     *
+     * The range is from 0 to 100, where 0 represents the minimum brightness and 100 represents
+     * the maximum brightness. The default/unmodified value is 50.
+     */
+    int colorTunerBrightness;
+
+    /*
+     * Adjust saturation in advance color engine. Similar to a "saturation" control on a TV
+     * but acts at a lower level.
+     *
+     * The range is from 0 to 100, where 0 being completely desaturated/grayscale and 100 being
+     * the most saturated. The default/unmodified value is 50.
+     */
+    int colorTunerSaturation;
+
+    /*
+     * Adjust hue in advance color engine. Similar to a "hue" control on a TV but acts at a lower
+     * level.
+     *
+     * The range is from -50 to 50, where -50 represents cooler setting for a specific color and 50
+     * represents warmer setting for a specific color. The default/unmodified value is 0.
+     */
+    int colorTunerHue;
+
+    /*
+     * Advance setting for red offset. Adjust the black level of red color channels, it control
+     * the minimum intensity of each color, affecting the shadows and dark areas of the image.
+     *
+     * The range is from 0 to 100, where 0 makes shadows darker and 100 makes shadows brighter.
+     * The default/unmodified value is 50.
+     */
+    int colorTunerRedOffset;
+
+    /*
+     * Advance setting for green offset. Adjust the black level of green color channels, it control
+     * the minimum intensity of each color, affecting the shadows and dark areas of the image.
+     *
+     * The range is from 0 to 100, where 0 makes shadows darker and 100 makes shadows brighter.
+     * The default/unmodified value is 50.
+     */
+    int colorTunerGreenOffset;
+
+    /*
+     * Advance setting for blue offset. Adjust the black level of blue color channels, it control
+     * the minimum intensity of each color, affecting the shadows and dark areas of the image.
+     *
+     * The range is from 0 to 100, where 0 makes shadows darker and 100 makes shadows brighter.
+     * The default/unmodified value is 50.
+     */
+    int colorTunerBlueOffset;
+
+    /*
+     * Advance setting for red gain. Adjust the gain or amplification of the red color channels.
+     * They control the overall intensity and white balance of red.
+     *
+     * The range is from 0 to 100, where 0 makes the red dimmer and 100 makes the red brighter.
+     * The default/unmodified value is 50.
+     */
+    int colorTunerRedGain;
+
+    /*
+     * Advance setting for green gain. Adjust the gain or amplification of the green color channels.
+     * They control the overall intensity and white balance of green.
+     *
+     * The range is from 0 to 100, where 0 makes the green dimmer and 100 makes the green brighter.
+     * The default/unmodified value is 50.
+     */
+    int colorTunerGreenGain;
+
+    /*
+     * Advance setting for blue gain. Adjust the gain or amplification of the blue color channels.
+     * They control the overall intensity and white balance of blue.
+     *
+     * The range is from 0 to 100, where 0 makes the blue dimmer and 100 makes the blue brighter.
+     * The default/unmodified value is 50.
+     */
+    int colorTunerBlueGain;
+
+    /* Noise reduction. (Off, Low, Medium, High) */
+    QualityLevel noiseReduction;
+
+    /* MPEG (moving picture experts group) noise reduction (Off, Low, Medium, High) */
+    QualityLevel mpegNoiseReduction;
+
+    /*
+     * Refine the flesh colors in the pictures without affecting the other colors on the screen.
+     * (Off, Low, Medium, High)
+     */
+    QualityLevel fleshTone;
+
+    /* Contour noise reduction. (Off, Low, Medium, High) */
+    QualityLevel deContour;
+
+    /* Dynamically change picture luma to enhance contrast. (Off, Low, Medium, High) */
+    QualityLevel dynamicLumaControl;
+
+    /* Enable/disable film mode */
+    boolean filmMode;
+
+    /* Enable/disable blue color auto stretch */
+    boolean blueStretch;
+
+    /* Enable/disable the overall color tuning feature. */
+    boolean colorTune;
+
+    /* Adjust color temperature type */
+    ColorTemperature colorTemperature;
+
+    /* Enable/disable globe dimming. */
+    boolean globeDimming;
+
+    /* Enable/disable auto adjust picture parameter based on the TV content. */
+    boolean autoPictureQualityEnabled;
+
+    /*
+     * Enable/disable auto upscaling the picture quality. It analyzes the lower-resolution
+     * image and uses its knowledge to invent the missing pixel, make the image look sharper.
+     */
+    boolean autoSuperResolutionEnabled;
 }