[Mesa-dev] [PATCH 95/95] i965/gen7: expose OpenGL 4.0 on Haswell
Iago Toral Quiroga
itoral at igalia.com
Tue Jul 19 10:41:32 UTC 2016
ARB_gpu_shader_fp64 was the last piece missing. Notice that some
hardware and kernel combinations do not support pipelined register
writes, which are required for some OpenGL 4.0 features, in which
case the driver won't expose 4.0.
---
src/mesa/drivers/dri/i965/intel_extensions.c | 2 ++
src/mesa/drivers/dri/i965/intel_screen.c | 8 ++++++++
2 files changed, 10 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c b/src/mesa/drivers/dri/i965/intel_extensions.c
index 6ba44b8..8363c02 100644
--- a/src/mesa/drivers/dri/i965/intel_extensions.c
+++ b/src/mesa/drivers/dri/i965/intel_extensions.c
@@ -270,6 +270,8 @@ intelInitExtensions(struct gl_context *ctx)
if (brw->gen >= 8)
ctx->Const.GLSLVersion = 430;
+ else if (brw->is_haswell)
+ ctx->Const.GLSLVersion = 400;
else if (brw->gen >= 6)
ctx->Const.GLSLVersion = 330;
else
diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
index 432ab7b..e7a1224 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.c
+++ b/src/mesa/drivers/dri/i965/intel_screen.c
@@ -1425,6 +1425,14 @@ set_max_gl_versions(struct intel_screen *screen)
psp->max_gl_es2_version = 31;
break;
case 7:
+ if (screen->devinfo->is_haswell) {
+ psp->max_gl_core_version = 40;
+ psp->max_gl_compat_version = 30;
+ psp->max_gl_es1_version = 11;
+ psp->max_gl_es2_version = 30;
+ break;
+ }
+ /* fallthrough */
case 6:
psp->max_gl_core_version = 33;
psp->max_gl_compat_version = 30;
--
2.7.4
More information about the mesa-dev
mailing list