[Mesa-dev] [PATCH] glsl: enable EXT_texture_array by default in 1.30

Ilia Mirkin imirkin at alum.mit.edu
Fri Jun 29 11:34:13 UTC 2018


NAK.

The extension was not made core in GL 3.0. Many of the features were
integrated into GL 3.0, but the actual extension text was not merged.
(As is often true with extensions' functionality being integrated into
core specs.) These enables control various functions like
texture2DArray() and so on -- these are not part of the GLSL 1.30
spec. (And GLSL 1.30 deprecated the previously existing textureType()
variants.)

On Fri, Jun 29, 2018 at 12:42 AM, Timothy Arceri <tarceri at itsqueeze.com> wrote:
> This extension was made core in OpenGL 3.0.
>
> This fixes rendering issues in No Man's Sky.
> ---
>  src/compiler/glsl/builtin_functions.cpp | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/src/compiler/glsl/builtin_functions.cpp b/src/compiler/glsl/builtin_functions.cpp
> index 7119903795f..787a72b49c5 100644
> --- a/src/compiler/glsl/builtin_functions.cpp
> +++ b/src/compiler/glsl/builtin_functions.cpp
> @@ -336,20 +336,22 @@ static bool
>  texture_array_lod(const _mesa_glsl_parse_state *state)
>  {
>     return lod_exists_in_stage(state) &&
> -          state->EXT_texture_array_enable;
> +          (state->is_version(130, 0) ||
> +           state->EXT_texture_array_enable);
>  }
>
>  static bool
>  fs_texture_array(const _mesa_glsl_parse_state *state)
>  {
>     return state->stage == MESA_SHADER_FRAGMENT &&
> -          state->EXT_texture_array_enable;
> +          (state->is_version(130, 0) ||
> +           state->EXT_texture_array_enable);
>  }
>
>  static bool
>  texture_array(const _mesa_glsl_parse_state *state)
>  {
> -   return state->EXT_texture_array_enable;
> +   return state->is_version(130, 0) || state->EXT_texture_array_enable;
>  }
>
>  static bool
> --
> 2.17.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list