gallium: give vertex-shader saturate its own cap

Shader Model 3.0 is a big promise to make to the state-tracker, and
for instance mobile hardware might support vertex-shader saturate but
not some of the other features of SM3. So let's give this its own cap
for simplicity.

Signed-off-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Erik Faye-Lund
2019-07-05 16:21:45 +02:00
parent 681fa03e8d
commit 21de1bf24b
4 changed files with 5 additions and 1 deletions

View File

@@ -686,7 +686,7 @@ st_create_context_priv(struct gl_context *ctx, struct pipe_context *pipe,
* is not supported
*/
ctx->Const.ShaderCompilerOptions[MESA_SHADER_VERTEX].EmitNoSat =
!screen->get_param(screen, PIPE_CAP_SM3);
!screen->get_param(screen, PIPE_CAP_VERTEX_SHADER_SATURATE);
if (ctx->Const.GLSLVersion < 400) {
for (i = 0; i < MESA_SHADER_STAGES; i++)