/icc-brightness-kde

Control OLED display brightness by applying ICC color profiles.

Primary LanguagePythonMIT LicenseMIT

ICC Brightness for KDE

Control OLED display brightness on KDE by applying ICC color profiles.

Forked from ICC Brightness

Introduction

This tool is a work-around for displays whose brightness contol is not supported by the linux kernel. It performs well on OLED displays, since these have very dark black point and their power consumption is relative to the brightness of the viewed content.

This tool can be used on an LCD display, but in that case you really want to control the brightness directly using the display backlight.

Specifically icc-brightness-kde was developed for the Lenovo ThinkPad P1 Gen2 with a 4k OLED display(Samsung panel).

Build and install

The build requires the liblcms2 development package and colord-kde:

$ sudo apt install liblcms2-dev colord-kde 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following NEW packages will be installed:
  liblcms2-dev
...

Build and run the tool to see all options:

$ make
gcc -W -Wall icc-brightness-gen.c -l lcms2 -o icc-brightness-gen
$ ./icc-brightness
Control OLED display brightness by applying ICC color profiles.
  
icc-brightness brightness max-brightness - set brightness manually
icc-brightness apply - apply brightness from system setting
icc-brightness watch - continuously update to system setting
icc-brightness clean - remove all profiles generated by us

You can install to auto-start a daemon when logging-in to a KDE session:

$ sudo make install
cp icc-brightness-gen /usr/local/bin/
cp icc-brightness /usr/local/bin/
cp icc-brightness.desktop /etc/xdg/autostart/

The daemon will start on your next login. You can change brightness using the brightness key or any other method that controls the display "backlight".