summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2017-02-14 16:18:24 +0100
committerSamuel Pitoiset <[email protected]>2017-02-15 16:15:32 +0100
commit9d16f3903e2caddb7f674ca7ab7b1e96cfffbb2b (patch)
treed04f78fb450fa43802ae5c137f6cd7f6f6095951 /src/mesa/drivers/dri
parentd1fae627fa63cf7749d4fb2ebb57ae5b13a7d5ef (diff)
driconf: add allow_higher_compat_version option
Mesa currently doesn't allow to create 3.1+ compatibility profiles mainly because various features are unimplemented and bugs can happen. However, some buggy apps request a compat profile without using any old features unimplemented in mesa, and they fail to start. This option should help some games to run but it's not enough for all (eg. Dying Light). v2: - s/force_compat_profile/allow_higher_compat_version Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Edmondo Tommasina <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/common/xmlpool/t_options.h5
-rw-r--r--src/mesa/drivers/dri/i965/brw_context.c3
2 files changed, 8 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/common/xmlpool/t_options.h b/src/mesa/drivers/dri/common/xmlpool/t_options.h
index a189bbedec6..f200093177d 100644
--- a/src/mesa/drivers/dri/common/xmlpool/t_options.h
+++ b/src/mesa/drivers/dri/common/xmlpool/t_options.h
@@ -115,6 +115,11 @@ DRI_CONF_OPT_BEGIN_B(allow_glsl_extension_directive_midshader, def) \
DRI_CONF_DESC(en,gettext("Allow GLSL #extension directives in the middle of shaders")) \
DRI_CONF_OPT_END
+#define DRI_CONF_ALLOW_HIGHER_COMPAT_VERSION(def) \
+DRI_CONF_OPT_BEGIN_B(allow_higher_compat_version, def) \
+ DRI_CONF_DESC(en,gettext("Allow a higher compat profile (version 3.1+) for apps that request it")) \
+DRI_CONF_OPT_END
+
/**
diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c
index 7240b1f4455..c56a14e3d66 100644
--- a/src/mesa/drivers/dri/i965/brw_context.c
+++ b/src/mesa/drivers/dri/i965/brw_context.c
@@ -916,6 +916,9 @@ brw_process_driconf_options(struct brw_context *brw)
ctx->Const.AllowGLSLExtensionDirectiveMidShader =
driQueryOptionb(options, "allow_glsl_extension_directive_midshader");
+ ctx->Const.AllowHigherCompatVersion =
+ driQueryOptionb(options, "allow_higher_compat_version");
+
ctx->Const.GLSLZeroInit = driQueryOptionb(options, "glsl_zero_init");
brw->dual_color_blend_by_location =