[Mesa-dev] [PATCH] glsl: default standalone compiler to 4.50

Timothy Arceri t_arceri at yahoo.com.au
Tue Aug 4 06:03:20 PDT 2015


On Fri, 2015-07-24 at 15:48 -0400, Ilia Mirkin wrote:
> Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
> ---
> 
> There seems to be a huge overlap between what initialize_context and
> initialize_context_to_defaults do, wasn't sure where to stick what.
> 
>  src/glsl/main.cpp | 26 +++++++++++++++++++++++++-
>  1 file changed, 25 insertions(+), 1 deletion(-)
> 
> diff --git a/src/glsl/main.cpp b/src/glsl/main.cpp
> index df93a01..fb98ef9 100644
> --- a/src/glsl/main.cpp
> +++ b/src/glsl/main.cpp
> @@ -39,7 +39,7 @@
>  #include "loop_analysis.h"
>  #include "standalone_scaffolding.h"
>  
> -static int glsl_version = 330;
> +static int glsl_version = 450;
>  
>  static void
>  initialize_context(struct gl_context *ctx, gl_api api)
> @@ -140,6 +140,22 @@ initialize_context(struct gl_context *ctx, gl_api api)
>  
>        ctx->Const.MaxVarying = ctx
> ->Const.Program[MESA_SHADER_VERTEX].MaxOutputComponents / 4;
>        break;
> +   case 400:
> +   case 410:
> +   case 420:
> +   case 430:
> +   case 440:

4.4 adds

ctx->Const.MaxVertexAttribStride = 2048;


> +   case 450:
> +      ctx->Const.Program[MESA_SHADER_TESS_CTRL].MaxTextureImageUnits = 16;
> +      ctx->Const.Program[MESA_SHADER_TESS_CTRL].MaxUniformComponents = 
> 1024;
> +      ctx->Const.Program[MESA_SHADER_TESS_CTRL].MaxInputComponents = 128;
> +      ctx->Const.Program[MESA_SHADER_TESS_CTRL].MaxOutputComponents = 128;
> +
> +      ctx->Const.Program[MESA_SHADER_TESS_EVAL].MaxTextureImageUnits = 16;
> +      ctx->Const.Program[MESA_SHADER_TESS_EVAL].MaxUniformComponents = 
> 1024;
> +      ctx->Const.Program[MESA_SHADER_TESS_EVAL].MaxInputComponents = 128;
> +      ctx->Const.Program[MESA_SHADER_TESS_EVAL].MaxOutputComponents = 128;
> +      /* fallthrough */
>     case 150:
>     case 330:
>        ctx->Const.MaxClipPlanes = 8;
> @@ -170,6 +186,8 @@ initialize_context(struct gl_context *ctx, gl_api api)
>  
>        ctx->Const.MaxCombinedTextureImageUnits =
>           ctx->Const.Program[MESA_SHADER_VERTEX].MaxTextureImageUnits
> +         + ctx->Const.Program[MESA_SHADER_TESS_CTRL].MaxTextureImageUnits
> +         + ctx->Const.Program[MESA_SHADER_TESS_EVAL].MaxTextureImageUnits
>           + ctx->Const.Program[MESA_SHADER_GEOMETRY].MaxTextureImageUnits
>           + ctx->Const.Program[MESA_SHADER_FRAGMENT].MaxTextureImageUnits;
>  
> @@ -327,6 +345,12 @@ main(int argc, char **argv)
>           case 140:
>           case 150:
>           case 330:
> +         case 400:
> +         case 410:
> +         case 420:
> +         case 430:
> +         case 440:
> +         case 450:
>              glsl_es = false;
>              break;
>           default:


More information about the mesa-dev mailing list