mesa: don't advertise bogus GL_ARB_shading_language_120 extension
Instead of using the invalid GL_ARB_shading_language_120 extension to determine the GLSL version, use a new ctx->Const.GLSLVersion field. Updated the intel and r600 drivers, but untested. See fd.o bug 29910 NOTE: This is a candidate for the 7.9 branch (but let's wait and see if there's any regressions).
This commit is contained in:
@@ -186,6 +186,11 @@ void st_init_limits(struct st_context *st)
|
||||
* attributes) supported by a driver. */
|
||||
c->MaxVarying = screen->get_shader_param(screen, PIPE_SHADER_FRAGMENT, PIPE_SHADER_CAP_MAX_INPUTS) - 2;
|
||||
c->MaxVarying = MIN2(c->MaxVarying, MAX_VARYING);
|
||||
|
||||
/* XXX we'll need a better query here someday */
|
||||
if (screen->get_param(screen, PIPE_CAP_GLSL)) {
|
||||
c->GLSLVersion = 120;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -285,7 +290,6 @@ void st_init_extensions(struct st_context *st)
|
||||
ctx->Extensions.ARB_vertex_shader = GL_TRUE;
|
||||
ctx->Extensions.ARB_shader_objects = GL_TRUE;
|
||||
ctx->Extensions.ARB_shading_language_100 = GL_TRUE;
|
||||
ctx->Extensions.ARB_shading_language_120 = GL_TRUE;
|
||||
}
|
||||
|
||||
if (screen->get_param(screen, PIPE_CAP_TEXTURE_MIRROR_REPEAT) > 0) {
|
||||
|
Reference in New Issue
Block a user