summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordevnoname1202017-04-10 01:13:51 +0200
committerSunguk Lee2017-04-13 04:11:40 +0900
commit1f6d23c049a2f676d341623ff92af1241d4b5efd (patch)
tree8ee6aab0594d58a3fae11b9724fcf11cb32dcd9e
parentAdded missing kernel IO headers. (#160) (diff)
downloadvds-libraries-1f6d23c049a2f676d341623ff92af1241d4b5efd.tar.gz
Add some brightness functions
-rw-r--r--include/user/avconfig.h34
-rw-r--r--nids/360/SceAVConfig.yml9
2 files changed, 43 insertions, 0 deletions
diff --git a/include/user/avconfig.h b/include/user/avconfig.h
new file mode 100644
index 0000000..fe0596d
--- /dev/null
+++ b/include/user/avconfig.h
@@ -0,0 +1,34 @@
+#ifndef _PSP2_AVCONFIG_H_
+#define _PSP2_AVCONFIG_H_
+
+#include <psp2/types.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/***
+ * Get the maximum brightness.
+ *
+ * @param[out] maxBrightness - Maximum brightness.
+ *
+ * @return 0 on success, < 0 on error.
+ */
+int sceAVConfigGetDisplayMaxBrightness(int *maxBrightness);
+
+/***
+ * Set the screen brightness.
+ *
+ * @param brightness - Brightness that the screen will be set to (range 21-65536, 0 turns off the screen).
+ *
+ * @return 0 on success, < 0 on error.
+ */
+int sceAVConfigSetDisplayBrightness(int brightness);
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
+
diff --git a/nids/360/SceAVConfig.yml b/nids/360/SceAVConfig.yml
new file mode 100644
index 0000000..5c54a41
--- /dev/null
+++ b/nids/360/SceAVConfig.yml
@@ -0,0 +1,9 @@
+modules:
+ SceAVConfig:
+ nid: 0x222DDEB1
+ libraries:
+ SceAVConfig:
+ nid: 0x79E0F03F
+ functions:
+ sceAVConfigGetDisplayMaxBrightness: 0x6ABA67F4
+ sceAVConfigSetDisplayBrightness: 0xE0C1B743