A simple GTK application to control brightness of displays including external displays supporting DDC/CI
yay -S luminance
Latest deb release is available on the releases page https://github.com/sidevesh/Luminance/releases
- Version 1.0.4 is the last supported version for Ubuntu before 24.04, Debian or any other Debian based distro that does not have atleast libadwaita 1.5 version
Latest rpm release is available on the releases page https://github.com/sidevesh/Luminance/releases
- GTK 4.0
- Libadwaita
- ddcutil library package (typically libddcutil or libddcutil-dev if not already installed with ddcutil)
- Make (Build tool)
- Meson (Build tool)
- Ninja (Build tool)
- GCC (Compiler)
-
Firstly, ensure that all the dependencies are installed:
pacman -S --needed make meson glib2-devel glib2 gtk4 libadwaita ddcutilsudo apt install make gcc meson libglib2.0-dev libgtk-4-dev libadwaita-1-dev libddcutil-devsudo dnf install make gcc meson glib2-devel gtk4-devel libadwaita-devel libddcutil-devel -
Ensure that your user has access to the i2c devices: https://www.ddcutil.com/i2c_permissions/
-
Clone this repo:
git clone --recurse-submodules https://github.com/sidevesh/Luminance.git -
Change into the
Luminancedirectory and build the application:cd Luminance make -
To install this binary for all users execute install command:
make installYou should now be able to find Luminance in your list of apps.
- Installing the application is necessary for it to work because it uses gsettings to store preferences and will need the schema files to be installed.
- Note: You might need to reload udev rules or reboot for brightness control permissions to take effect.
To build a development version (which installs as com.sidevesh.Luminance.Devel and allows side-by-side installation with the release version):
make install-debug
To build the application as a Flatpak:
make flatpak
To install the locally built Flatpak:
make install-flatpak
To uninstall the locally built Flatpak:
make uninstall-flatpak
To run the installed Flatpak with GDB for debugging:
make run-flatpak
To create a standalone Flatpak bundle:
make flatpak-bundle
To uninstall the application, run the following from the build directory:
make uninstallOr for the debug build:
make uninstall-debugStart the application normally or you can also use the app via cli interface:
Usage: com.sidevesh.Luminance [OPTIONS]
An application to control brightness of displays including external displays supporting DDC/CI
Options:
-l, --list-displays List displays and their brightness
-g, --get-percentage [DISPLAY NUMBER] Get the brightness percentage of a display
-s, --set-brightness [DISPLAY NUMBER] Set the brightness of a display to a percentage value
-i, --increase-brightness [DISPLAY NUMBER] Increase the brightness of a display by a percentage value
-d, --decrease-brightness [DISPLAY NUMBER] Decrease the brightness of a display by a percentage value
If DISPLAY NUMBER is not provided, for --set-brightness, --increase-brightness and --decrease-brightness options, the brightness of all displays will be changed
-p --percentage [PERCENTAGE] Percentage value to set the brightness to in case of --set-brightness option or to increase or decrease the brightness by in case of --increase-brightness or --decrease-brightness option
-h, --help Show help information
When no arguments are provided, the application starts in GUI mode.
Switch the arch submodule push url to the ssh url before pushing to AUR for the first time:
cd arch
git remote set-url --push origin ssh://aur@aur.archlinux.org/luminance.git
- Install
flatpak: - Install
flatpak-builder(It is recommended to use the flatpak version of the builder):flatpak install -y flathub org.flatpak.Builder - Install the required GNOME Runtime and SDK:
flatpak install org.gnome.Platform//48 org.gnome.Sdk//48
To build and install the Flatpak locally for testing:
make flatpak-install
To validate the manifest and repository against Flathub requirements:
make flatpak-lint
make flatpak-run
To create a binary bundle .flatpak for distribution:
make flatpak-bundle
Distributed under the GNU General Public License v3.0. See LICENSE.txt for more information.
Swapnil Devesh - @sid_devesh - me@sidevesh.com
Project Link: https://github.com/sidevesh/Luminance
- @ahshabbir : for ddcbc-api and ddcbc-gtk: https://github.com/ahshabbir/ddcbc-api
- @rockowitz : for ddcutil c api: https://github.com/rockowitz/ddcutil
- @jimmac : for the awesome icon: https://github.com/jimmac
