summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAli B <abittin@gmail.com>2019-05-08 08:58:48 +0300
committerAli B <abittin@gmail.com>2019-05-14 20:12:26 +0300
commit5bcf9bc45d09f8dee50a2ce3c92040f2796eaa01 (patch)
treed31a68f399adbb5c3e7634c6efe24fc71244c5b6
parentbe4d744b1b7133f28caeeb484b6edd8e1031df2e (diff)
Bring in livedisplay from Lineage
Change-Id: Idd10e4d034ae74537a1f5f0f18c2cedef82ec7e3
-rw-r--r--livedisplay/2.0/Android.bp29
-rw-r--r--livedisplay/2.0/IAdaptiveBacklight.hal22
-rw-r--r--livedisplay/2.0/IAutoContrast.hal22
-rw-r--r--livedisplay/2.0/IColorBalance.hal23
-rw-r--r--livedisplay/2.0/IColorEnhancement.hal22
-rw-r--r--livedisplay/2.0/IDisplayColorCalibration.hal24
-rw-r--r--livedisplay/2.0/IDisplayModes.hal24
-rw-r--r--livedisplay/2.0/IPictureAdjustment.hal29
-rw-r--r--livedisplay/2.0/IReadingEnhancement.hal22
-rw-r--r--livedisplay/2.0/ISunlightEnhancement.hal22
-rw-r--r--livedisplay/2.0/types.hal42
11 files changed, 281 insertions, 0 deletions
diff --git a/livedisplay/2.0/Android.bp b/livedisplay/2.0/Android.bp
new file mode 100644
index 0000000..63c75c5
--- /dev/null
+++ b/livedisplay/2.0/Android.bp
@@ -0,0 +1,29 @@
+// This file is autogenerated by hidl-gen -Landroidbp.
+
+hidl_interface {
+ name: "vendor.lineage.livedisplay@2.0",
+ root: "vendor.lineage",
+ srcs: [
+ "types.hal",
+ "IAdaptiveBacklight.hal",
+ "IAutoContrast.hal",
+ "IColorBalance.hal",
+ "IColorEnhancement.hal",
+ "IDisplayColorCalibration.hal",
+ "IDisplayModes.hal",
+ "IPictureAdjustment.hal",
+ "IReadingEnhancement.hal",
+ "ISunlightEnhancement.hal",
+ ],
+ interfaces: [
+ "android.hidl.base@1.0",
+ ],
+ types: [
+ "DisplayMode",
+ "FloatRange",
+ "HSIC",
+ "Range",
+ ],
+ gen_java: true,
+}
+
diff --git a/livedisplay/2.0/IAdaptiveBacklight.hal b/livedisplay/2.0/IAdaptiveBacklight.hal
new file mode 100644
index 0000000..cc449d1
--- /dev/null
+++ b/livedisplay/2.0/IAdaptiveBacklight.hal
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IAdaptiveBacklight {
+ isEnabled() generates (bool rc);
+ setEnabled(bool enabled) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IAutoContrast.hal b/livedisplay/2.0/IAutoContrast.hal
new file mode 100644
index 0000000..929ac34
--- /dev/null
+++ b/livedisplay/2.0/IAutoContrast.hal
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IAutoContrast {
+ isEnabled() generates (bool rc);
+ setEnabled(bool enabled) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IColorBalance.hal b/livedisplay/2.0/IColorBalance.hal
new file mode 100644
index 0000000..fc8d1e0
--- /dev/null
+++ b/livedisplay/2.0/IColorBalance.hal
@@ -0,0 +1,23 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IColorBalance {
+ getColorBalanceRange() generates (Range range);
+ getColorBalance() generates (int32_t value);
+ setColorBalance(int32_t value) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IColorEnhancement.hal b/livedisplay/2.0/IColorEnhancement.hal
new file mode 100644
index 0000000..0be9e7f
--- /dev/null
+++ b/livedisplay/2.0/IColorEnhancement.hal
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IColorEnhancement {
+ isEnabled() generates (bool rc);
+ setEnabled(bool enabled) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IDisplayColorCalibration.hal b/livedisplay/2.0/IDisplayColorCalibration.hal
new file mode 100644
index 0000000..6a3968e
--- /dev/null
+++ b/livedisplay/2.0/IDisplayColorCalibration.hal
@@ -0,0 +1,24 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IDisplayColorCalibration {
+ getMaxValue() generates (int32_t max);
+ getMinValue() generates (int32_t min);
+ getCalibration() generates (vec<int32_t> rgb);
+ setCalibration(vec<int32_t> rgb) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IDisplayModes.hal b/livedisplay/2.0/IDisplayModes.hal
new file mode 100644
index 0000000..8174fc4
--- /dev/null
+++ b/livedisplay/2.0/IDisplayModes.hal
@@ -0,0 +1,24 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IDisplayModes {
+ getDisplayModes() generates (vec<DisplayMode> modes);
+ getCurrentDisplayMode() generates (DisplayMode mode);
+ getDefaultDisplayMode() generates (DisplayMode mode);
+ setDisplayMode(int32_t modeID, bool makeDefault) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IPictureAdjustment.hal b/livedisplay/2.0/IPictureAdjustment.hal
new file mode 100644
index 0000000..04864a1
--- /dev/null
+++ b/livedisplay/2.0/IPictureAdjustment.hal
@@ -0,0 +1,29 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IPictureAdjustment {
+ getHueRange() generates (FloatRange range);
+ getSaturationRange() generates (FloatRange range);
+ getIntensityRange() generates (FloatRange range);
+ getContrastRange() generates (FloatRange range);
+ getSaturationThresholdRange() generates (FloatRange range);
+
+ getPictureAdjustment() generates (HSIC hsic);
+ getDefaultPictureAdjustment() generates (HSIC hsic);
+ setPictureAdjustment(HSIC hsic) generates (bool rc);
+};
diff --git a/livedisplay/2.0/IReadingEnhancement.hal b/livedisplay/2.0/IReadingEnhancement.hal
new file mode 100644
index 0000000..25d7970
--- /dev/null
+++ b/livedisplay/2.0/IReadingEnhancement.hal
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface IReadingEnhancement {
+ isEnabled() generates (bool rc);
+ setEnabled(bool enabled) generates (bool rc);
+};
diff --git a/livedisplay/2.0/ISunlightEnhancement.hal b/livedisplay/2.0/ISunlightEnhancement.hal
new file mode 100644
index 0000000..8e93cd9
--- /dev/null
+++ b/livedisplay/2.0/ISunlightEnhancement.hal
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2018-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+interface ISunlightEnhancement {
+ isEnabled() generates (bool rc);
+ setEnabled(bool enabled) generates (bool rc);
+};
diff --git a/livedisplay/2.0/types.hal b/livedisplay/2.0/types.hal
new file mode 100644
index 0000000..85e8802
--- /dev/null
+++ b/livedisplay/2.0/types.hal
@@ -0,0 +1,42 @@
+/*
+ * Copyright (C) 2017-2019 The LineageOS 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 vendor.lineage.livedisplay@2.0;
+
+struct Range {
+ int32_t max;
+ int32_t min;
+ uint32_t step;
+};
+
+struct FloatRange {
+ float max;
+ float min;
+ float step;
+};
+
+struct HSIC {
+ float hue;
+ float saturation;
+ float intensity;
+ float contrast;
+ float saturationThreshold;
+};
+
+struct DisplayMode {
+ int32_t id;
+ string name;
+};