mirror of
https://github.com/ublue-os/bazzite.git
synced 2025-01-01 12:02:58 +00:00
fix(steam): Fix flickering in nvidia cards (#1251)
This fixes the flickering introduced in commit 6500fed
Co-authored-by: pull[bot] <39814207+pull[bot]@users.noreply.github.com>
This commit is contained in:
parent
ca3d605304
commit
548a9ccce0
@ -12,11 +12,16 @@ if [[ $IMAGE_NAME =~ "deck" || $IMAGE_NAME =~ "ally" || $IMAGE_NAME =~ "framegam
|
||||
fi
|
||||
fi
|
||||
|
||||
switcheroo_state="$(switcherooctl list)"
|
||||
DGPU_OPTION=""
|
||||
# If we're running this on a dGPU, apply workaround for blank Steam window
|
||||
if [[ $(switcherooctl list | grep -o 'Device:' | wc -l) -gt 1 ]]; then
|
||||
DGPU_OPTION="-system-composer"
|
||||
if [[ $(echo "${switcheroo_state}" | grep -o 'Device:' | wc -l) -gt 1 ]]; then
|
||||
# TODO: Check if -system-composer is needed with nvidia >=555 driver
|
||||
if ! grep -Pq 'Name:\s+NVIDIA' <<< "$switcheroo_state"; then
|
||||
DGPU_OPTION="-system-composer"
|
||||
fi
|
||||
fi
|
||||
unset -v switcheroo_state
|
||||
|
||||
if [[ "$XDG_SESSION_TYPE" == "wayland" ]]; then
|
||||
# https://github.com/Supreeeme/extest
|
||||
|
Loading…
Reference in New Issue
Block a user