set_region(region: object<wl_region>)
Argument
Type
Description
regionobject<wl_region>allow null
set_contrast(contrast: fixed)
Argument
Type
Description
contrastfixed
set_intensity(intensity: fixed)
Argument
Type
Description
intensityfixed
set_saturation(saturation: fixed)
Argument
Type
Description
saturationfixed
release()
release the contrast object
set_frost(red: int, green: int, blue: int, alpha: int)
Argument
Type
Description
redint
greenint
blueint
alphaint
opt into frost effect w/ given colour

enables 'frost' variant of contrast effect.

'frost' is an enhanced version of the contrast effect that uses different colour arithmetic to get backgrounds simultaneously higher in contrast and (apparent) transparency.

r, g, b, a are channels from 0-255, indicating a colour to use in contrast calculation. should be based off of the "main" background colour of the surface.

unset_frost()
opts out of frost effect

Compositor Support

Cage
Cage
0.2.0
COSMIC
COSMIC
1.0.0~beta.8
GameScope
GameScope
3.15.14
Hyprland
Hyprland
0.52.1
Jay
1.11.0
KWin
KWin
6.4
Labwc
Labwc
0.9.2
Louvre
Louvre
2.14.1
Mir
Mir
2.19
Muffin
Muffin
6.4.1
Mutter
Mutter
49.2
niri
niri
25.11
river
river
0.3.13
Sway
Sway
1.11
Treeland
Treeland
0.8.0
Wayfire
Wayfire
0.9.0
Weston
Weston
14.0.2
org_kde_kwin_contrast_manager
x
x
x
x
x
2
x
x
x
x
x
x
x
x
x
x
x

SPDX-FileCopyrightText: 2015 Martin Gräßlin SPDX-FileCopyrightText: 2015 Marco Martin

SPDX-License-Identifier: LGPL-2.1-or-later