glsl: add ARB_bindless_texture enable
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Tue, 21 Mar 2017 11:42:47 +0000 (12:42 +0100)
committerSamuel Pitoiset <samuel.pitoiset@gmail.com>
Sat, 6 May 2017 14:40:19 +0000 (16:40 +0200)
This also adds the extension to the standalone GLSL compiler.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/compiler/glsl/glsl_parser_extras.cpp
src/compiler/glsl/glsl_parser_extras.h
src/compiler/glsl/standalone_scaffolding.cpp

index eb12efff8aa9d7bab245d3153e4638f7697d126e..b7303aba4217b91366ab0a192cafb53b4bcf40b4 100644 (file)
@@ -607,6 +607,7 @@ static const _mesa_glsl_extension _mesa_glsl_supported_extensions[] = {
    EXT(ARB_ES3_1_compatibility),
    EXT(ARB_ES3_2_compatibility),
    EXT(ARB_arrays_of_arrays),
+   EXT(ARB_bindless_texture),
    EXT(ARB_compute_shader),
    EXT(ARB_compute_variable_group_size),
    EXT(ARB_conservative_depth),
index 6c3bc8a91735efef7a6d40e3af90e49376612bd2..6045a6128e6b4828ff9f735f24af6617897d46e8 100644 (file)
@@ -334,6 +334,11 @@ struct _mesa_glsl_parse_state {
       return ARB_shader_image_load_store_enable || is_version(420, 310);
    }
 
+   bool has_bindless() const
+   {
+      return ARB_bindless_texture_enable;
+   }
+
    void process_version_directive(YYLTYPE *locp, int version,
                                   const char *ident);
 
@@ -592,6 +597,8 @@ struct _mesa_glsl_parse_state {
    bool ARB_ES3_2_compatibility_warn;
    bool ARB_arrays_of_arrays_enable;
    bool ARB_arrays_of_arrays_warn;
+   bool ARB_bindless_texture_enable;
+   bool ARB_bindless_texture_warn;
    bool ARB_compute_shader_enable;
    bool ARB_compute_shader_warn;
    bool ARB_compute_variable_group_size_enable;
index 5f1b2d0c3121462c78ac5005e0992b2ea61d3a94..d85650ab7aef62753753ec7d49ce1ecd116fa0b2 100644 (file)
@@ -196,6 +196,7 @@ void initialize_context_to_defaults(struct gl_context *ctx, gl_api api)
    ctx->Extensions.ARB_uniform_buffer_object = true;
    ctx->Extensions.ARB_viewport_array = true;
    ctx->Extensions.ARB_cull_distance = true;
+   ctx->Extensions.ARB_bindless_texture = true;
 
    ctx->Extensions.OES_EGL_image_external = true;
    ctx->Extensions.OES_standard_derivatives = true;