Mesa (master): drirc: Set glsl_zero_init for Kerbal Space Program.
Francisco Jerez
currojerez at kemper.freedesktop.org
Tue Apr 4 21:17:20 UTC 2017
Module: Mesa
Branch: master
Commit: 0de17f52a515e655682b4b894c44ad9d7308794e
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=0de17f52a515e655682b4b894c44ad9d7308794e
Author: Francisco Jerez <currojerez at riseup.net>
Date: Tue Apr 4 14:12:59 2017 -0700
drirc: Set glsl_zero_init for Kerbal Space Program.
This fixes the stripes of garbage rendered on the floor of the vehicle
assembly building among other rendering issues. The reason for the
misrendering seems to be that some of the GLSL shaders used by the
application use variables before initializing them, incorrectly
assuming that they will be implicitly set to zero by the
implementation.
Acked-by: Matt Turner <mattst88 at gmail.com>
---
src/mesa/drivers/dri/common/drirc | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/mesa/drivers/dri/common/drirc b/src/mesa/drivers/dri/common/drirc
index 23d09fabb1..14d7713fdc 100644
--- a/src/mesa/drivers/dri/common/drirc
+++ b/src/mesa/drivers/dri/common/drirc
@@ -128,5 +128,13 @@ TODO: document the other workarounds.
<application name="Spec Ops: The Line (64-bit)" executable="specops">
<option name="force_glsl_abs_sqrt" value="true" />
</application>
+
+ <application name="Kerbal Space Program (32-bit)" executable="KSP.x86">
+ <option name="glsl_zero_init" value="true"/>
+ </application>
+
+ <application name="Kerbal Space Program (64-bit)" executable="KSP.x86_64">
+ <option name="glsl_zero_init" value="true"/>
+ </application>
</device>
</driconf>
More information about the mesa-commit
mailing list