summaryrefslogtreecommitdiffstats
path: root/src/mesa/program/ir_to_mesa.cpp
diff options
context:
space:
mode:
authorTimothy Arceri <[email protected]>2017-08-22 20:31:57 +1000
committerTimothy Arceri <[email protected]>2017-08-22 21:25:55 +1000
commitda28280544139ff58124224863c69211a50e37ec (patch)
tree3e6a930381290f556fffce25b7f111b7a404be21 /src/mesa/program/ir_to_mesa.cpp
parent640b6e607cb25d0ccc2bf1a1c609f497eb10f673 (diff)
mesa: pass ctx to add_uniform_to_shader constructor
Fixes: 4c2422067b5c ("glsl: pass UseSTD430AsDefaultPacking to where it will be used") Reviewed-by: Samuel Pitoiset <[email protected]>
Diffstat (limited to 'src/mesa/program/ir_to_mesa.cpp')
-rw-r--r--src/mesa/program/ir_to_mesa.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/mesa/program/ir_to_mesa.cpp b/src/mesa/program/ir_to_mesa.cpp
index c168162b572..78f24498783 100644
--- a/src/mesa/program/ir_to_mesa.cpp
+++ b/src/mesa/program/ir_to_mesa.cpp
@@ -2416,7 +2416,8 @@ namespace {
class add_uniform_to_shader : public program_resource_visitor {
public:
- add_uniform_to_shader(struct gl_shader_program *shader_program,
+ add_uniform_to_shader(struct gl_context *ctx,
+ struct gl_shader_program *shader_program,
struct gl_program_parameter_list *params)
: ctx(ctx), params(params), idx(-1)
{
@@ -2482,13 +2483,14 @@ add_uniform_to_shader::visit_field(const glsl_type *type, const char *name,
* \param params Parameter list to be filled in.
*/
void
-_mesa_generate_parameters_list_for_uniforms(struct gl_shader_program
+_mesa_generate_parameters_list_for_uniforms(struct gl_context *ctx,
+ struct gl_shader_program
*shader_program,
struct gl_linked_shader *sh,
struct gl_program_parameter_list
*params)
{
- add_uniform_to_shader add(shader_program, params);
+ add_uniform_to_shader add(ctx, shader_program, params);
foreach_in_list(ir_instruction, node, sh->ir) {
ir_variable *var = node->as_variable();
@@ -2850,7 +2852,7 @@ get_mesa_program(struct gl_context *ctx,
v.shader_program = shader_program;
v.options = options;
- _mesa_generate_parameters_list_for_uniforms(shader_program, shader,
+ _mesa_generate_parameters_list_for_uniforms(ctx, shader_program, shader,
prog->Parameters);
/* Emit Mesa IR for main(). */