<div dir="ltr"><div>Reviewed-by: Marek Olšák <<a href="mailto:marek.olsak@amd.com">marek.olsak@amd.com</a>><br><br></div>Marek<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Apr 10, 2018 at 7:40 AM, Timothy Arceri <span dir="ltr"><<a href="mailto:tarceri@itsqueeze.com" target="_blank">tarceri@itsqueeze.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Drivers that only support compat 3.0 were reporting GLSL 1.40<br>
support. This fixes issues with the menu of Dawn of War II.<br>
<br>
Fixes: a0c8b49284ef "mesa: enable OpenGL 3.1 with ARB_compatibility"<br>
<br>
Bugzilla: <a href="https://bugs.freedesktop.org/show_bug.cgi?id=105807" rel="noreferrer" target="_blank">https://bugs.freedesktop.org/<wbr>show_bug.cgi?id=105807</a><br>
---<br>
src/mesa/main/version.c | 8 ++++++--<br>
1 file changed, 6 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/src/mesa/main/version.c b/src/mesa/main/version.c<br>
index 0a4e7630da6..84babd69e2f 100644<br>
--- a/src/mesa/main/version.c<br>
+++ b/src/mesa/main/version.c<br>
@@ -620,8 +620,11 @@ _mesa_compute_version(struct gl_context *ctx)<br>
/* Make sure that the GLSL version lines up with the GL version. In some<br>
* cases it can be too high, e.g. if an extension is missing.<br>
*/<br>
- if (_mesa_is_desktop_gl(ctx) && ctx->Version >= 31) {<br>
+ if (_mesa_is_desktop_gl(ctx)) {<br>
switch (ctx->Version) {<br>
+ case 30:<br>
+ ctx->Const.GLSLVersion = 130;<br>
+ break;<br>
case 31:<br>
ctx->Const.GLSLVersion = 140;<br>
break;<br>
@@ -629,7 +632,8 @@ _mesa_compute_version(struct gl_context *ctx)<br>
ctx->Const.GLSLVersion = 150;<br>
break;<br>
default:<br>
- ctx->Const.GLSLVersion = ctx->Version * 10;<br>
+ if (ctx->Version >= 33)<br>
+ ctx->Const.GLSLVersion = ctx->Version * 10;<br>
break;<br>
}<br>
}<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.17.0<br>
<br>
______________________________<wbr>_________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div>