summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlejandro Piñeiro <[email protected]>2018-01-04 16:51:19 +0100
committerAlejandro Piñeiro <[email protected]>2018-01-05 08:52:22 +0100
commit8dcf131f04cf0fd540de127481985010ae61a4ea (patch)
treea8fd5fb5c797d27267447b005638265de12ef6a6 /src
parent937b210551ef7c243976f0c0240395827a72ef8b (diff)
glsl/standalone: set MaxUniformBufferBindings
Used to handle how many ubo you can define on the context. Minimimum defined as 36 on ARB_uniform_buffer_object spec, up to 84 on OpenGL 4.6 (12 per stage at each moment). Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/compiler/glsl/standalone.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/compiler/glsl/standalone.cpp b/src/compiler/glsl/standalone.cpp
index 85e94a1095b..5035cbdce45 100644
--- a/src/compiler/glsl/standalone.cpp
+++ b/src/compiler/glsl/standalone.cpp
@@ -229,6 +229,7 @@ initialize_context(struct gl_context *ctx, gl_api api)
ctx->Const.MaxLights = 8;
ctx->Const.MaxTextureCoordUnits = 8;
ctx->Const.MaxTextureUnits = 2;
+ ctx->Const.MaxUniformBufferBindings = 84;
ctx->Const.Program[MESA_SHADER_VERTEX].MaxAttribs = 16;
ctx->Const.Program[MESA_SHADER_VERTEX].MaxTextureImageUnits = 16;
@@ -262,6 +263,7 @@ initialize_context(struct gl_context *ctx, gl_api api)
ctx->Const.MaxLights = 8;
ctx->Const.MaxTextureCoordUnits = 8;
ctx->Const.MaxTextureUnits = 2;
+ ctx->Const.MaxUniformBufferBindings = 84;
ctx->Const.Program[MESA_SHADER_VERTEX].MaxAttribs = 16;
ctx->Const.Program[MESA_SHADER_VERTEX].MaxTextureImageUnits = 16;
@@ -303,6 +305,7 @@ initialize_context(struct gl_context *ctx, gl_api api)
ctx->Const.MaxLights = 0;
ctx->Const.MaxTextureCoordUnits = 0;
ctx->Const.MaxTextureUnits = 0;
+ ctx->Const.MaxUniformBufferBindings = 84;
ctx->Const.Program[MESA_SHADER_VERTEX].MaxAttribs = 16;
ctx->Const.Program[MESA_SHADER_VERTEX].MaxTextureImageUnits = 16;