fix: added workaround for work with nvk
Signed-off-by: Boris Yumankulov <boria138@altlinux.org>
This commit is contained in:
@ -7,23 +7,19 @@ for i in "${HOME}"/.config/environment.d/*.conf; do
|
|||||||
done
|
done
|
||||||
set +a
|
set +a
|
||||||
|
|
||||||
# Fix intel color corruption
|
# Gamescope parameters
|
||||||
# might come with some performance degradation but is better than a corrupted
|
GAMESCOPE_PARAMS=""
|
||||||
# color image
|
|
||||||
export INTEL_DEBUG=norbc
|
|
||||||
export mesa_glthread=true
|
|
||||||
|
|
||||||
# This should be used by default by gamescope. Cannot hurt to force it anyway.
|
# Check if NVK driver is in use
|
||||||
# Reported better framelimiting with this enabled
|
if vulkaninfo 2>/dev/null | grep -i "driverName" | grep -q "NVK"; then
|
||||||
export ENABLE_GAMESCOPE_WSI=1
|
# Workaround for https://gitlab.freedesktop.org/mesa/mesa/-/issues/13478
|
||||||
|
GAMESCOPE_PARAMS+=" --backend sdl -f"
|
||||||
# Some environment variables by default (taken from Deck session)
|
|
||||||
export SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS=0
|
|
||||||
|
|
||||||
# Add custom vulkan adapter if specified
|
|
||||||
if [ -n "$VULKAN_ADAPTER" ]; then
|
|
||||||
GAMESCOPECMD= " --prefer-vk-device $VULKAN_ADAPTER"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Start client application
|
# Prefer a specific Vulkan adapter if defined
|
||||||
gamescope $GAMESCOPECMD -- portprotonqt --fullscreen
|
if [ -n "$VULKAN_ADAPTER" ]; then
|
||||||
|
GAMESCOPE_PARAMS+=" --prefer-vk-device $VULKAN_ADAPTER"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Start client application with Gamescope
|
||||||
|
gamescope $GAMESCOPE_PARAMS -- portprotonqt --fullscreen
|
||||||
|
Reference in New Issue
Block a user