summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteve Kondik <steve@cyngn.com>2016-07-21 23:57:01 -0700
committerSteve Kondik <steve@cyngn.com>2016-07-31 13:54:44 -0700
commita8ef044be1eb70c0f8a17f0c40d4c5c08bf71593 (patch)
tree1ea03f36c6d902bd2479042c086969326997c144
parent40bc2f399c75c33cdad191f8fdfd66c5babe9abd (diff)
downloadandroid_hardware_lineage_lineagehw-a8ef044be1eb70c0f8a17f0c40d4c5c08bf71593.tar.gz
android_hardware_lineage_lineagehw-a8ef044be1eb70c0f8a17f0c40d4c5c08bf71593.tar.bz2
android_hardware_lineage_lineagehw-a8ef044be1eb70c0f8a17f0c40d4c5c08bf71593.zip
cmhw: Add PictureAdjustment stubs
* Enables adjustment of hue/saturation/intensity/contrast levels of the display. Change-Id: I6b562324a27649809e41fa223445e517c262cca2
-rw-r--r--src/org/cyanogenmod/hardware/PictureAdjustment.java103
1 files changed, 103 insertions, 0 deletions
diff --git a/src/org/cyanogenmod/hardware/PictureAdjustment.java b/src/org/cyanogenmod/hardware/PictureAdjustment.java
new file mode 100644
index 0000000..bbde0e0
--- /dev/null
+++ b/src/org/cyanogenmod/hardware/PictureAdjustment.java
@@ -0,0 +1,103 @@
+/*
+ * Copyright (C) 2016 The CyanogenMod 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 org.cyanogenmod.hardware;
+
+import android.annotation.TargetApi;
+import android.util.Range;
+
+import cyanogenmod.hardware.HSIC;
+
+/**
+ * Picture adjustment support
+ *
+ * Allows tuning of hue, saturation, intensity, and contrast levels
+ * of the display
+ */
+public class PictureAdjustment {
+
+ /**
+ * Whether device supports picture adjustment
+ *
+ * @return boolean Supported devices must return always true
+ */
+ public static boolean isSupported() {
+ return false;
+ }
+
+ /**
+ * This method returns the current picture adjustment values
+ *
+ * @return the HSIC object or null if not supported
+ */
+ public static HSIC getHSIC() {
+ return null;
+ }
+
+ /**
+ * This method allows to set the picture adjustment
+ *
+ * @param hsic
+ * @return boolean Must be false if feature is not supported or the operation
+ * failed; true in any other case.
+ */
+ public static boolean setHSIC(final HSIC hsic) {
+ return false;
+ }
+
+ /**
+ * Get the range available for hue adjustment
+ * @return range of floats
+ */
+ public static Range<Float> getHueRange() {
+ return new Range(0.0f, 0.0f);
+ }
+
+ /**
+ * Get the range available for saturation adjustment
+ * @return range of floats
+ */
+ public static Range<Float> getSaturationRange() {
+ return new Range(0.0f, 0.0f);
+ }
+
+ /**
+ * Get the range available for intensity adjustment
+ * @return range of floats
+ */
+ public static Range<Float> getIntensityRange() {
+ return new Range(0.0f, 0.0f);
+ }
+
+ /**
+ * Get the range available for contrast adjustment
+ * @return range of floats
+ */
+ public static Range<Float> getContrastRange() {
+ return new Range(0.0f, 0.0f);
+ }
+
+ /**
+ * Get the range available for saturation threshold adjustment
+ *
+ * This is the threshold where the display becomes fully saturated
+ *
+ * @return range of floats
+ */
+ public static Range<Float> getSaturationThresholdRange() {
+ return new Range(0.0f, 0.0f);
+ }
+}