Update display.sh

This commit is contained in:
Kroese
2026-09-07 01:07:39 +02:00
committed by GitHub
parent 7e519f7b6d
commit e0eb426ea9
+28 -15
View File
@@ -34,20 +34,8 @@ if [ -z "$VGA" ]; then
VGA="vmvga"
if enabled "${DEBUG_GPU:-}"; then
VGA+=",debug=on"
fi
if enabled "$GPU"; then
if [[ "${VGPU,,}" != "auto" ]]; then
VGA+=",vgpu=$VGPU"
fi
else
VGA+=",3d=off"
version_file="$(st)"
if [ -s "$version_file" ]; then
@@ -336,7 +324,7 @@ vmwareVulkanReady() {
return 0
}
vmwareGpuSetup() {
vmvgaGpuSetup() {
VMWARE_LIBRARY_REASON=""
VMWARE_RENDER_REASON=""
@@ -367,6 +355,31 @@ vmwareGpuSetup() {
return 0
}
vmvgaSetup() {
if enabled "${DEBUG_GPU:-}"; then
DISPLAY_OPTS+=",debug=on"
fi
if enabled "$GPU"; then
if [[ "${VGPU,,}" != "auto" ]]; then
DISPLAY_OPTS+=",vgpu=$VGPU"
fi
else
DISPLAY_OPTS+=",3d=off"
fi
return 0
}
if [[ "${VGA_DEVICE,,}" == "vmvga" ]]; then
vmvgaSetup
fi
enabled "$GPU" || return 0
msg="Configuring display drivers..."
@@ -376,8 +389,8 @@ if [[ "$ARCH" != "amd64" ]]; then
gpuSetupFailure "GPU acceleration is only supported for the AMD64 platform"
fi
if [[ "${VGA_DEVICE,,}" == "vmware-svga" ]]; then
vmwareGpuSetup
if [[ "${VGA_DEVICE,,}" == "vmvga" ]]; then
vmvgaGpuSetup
return 0
fi