}
}
- vec4_visitor v(brw, c, prog_data, prog, shader, mem_ctx);
+ vec4_vs_visitor v(brw, c, prog_data, prog, shader, mem_ctx);
if (!v.run()) {
prog->LinkStatus = false;
ralloc_strcat(&prog->InfoLog, v.fail_msg);
void dump_instructions();
};
+class vec4_vs_visitor : public vec4_visitor
+{
+public:
+ vec4_vs_visitor(struct brw_context *brw,
+ struct brw_vs_compile *c,
+ struct brw_vs_prog_data *prog_data,
+ struct gl_shader_program *prog,
+ struct brw_shader *shader,
+ void *mem_ctx);
+};
+
/**
* The vertex shader code generator.
*
}
+vec4_vs_visitor::vec4_vs_visitor(struct brw_context *brw,
+ struct brw_vs_compile *c,
+ struct brw_vs_prog_data *prog_data,
+ struct gl_shader_program *prog,
+ struct brw_shader *shader,
+ void *mem_ctx)
+ : vec4_visitor(brw, c, prog_data, prog, shader, mem_ctx)
+{
+}
+
+
void
vec4_visitor::fail(const char *format, ...)
{
vec4_visitor *v;
};
+
+class register_coalesce_vec4_visitor : public vec4_visitor
+{
+public:
+ register_coalesce_vec4_visitor(struct brw_context *brw,
+ struct brw_vs_compile *c,
+ struct gl_shader_program *shader_prog)
+ : vec4_visitor(brw, c, NULL, shader_prog, NULL, NULL)
+ {
+ }
+};
+
+
void register_coalesce_test::SetUp()
{
brw = (struct brw_context *)calloc(1, sizeof(*brw));
shader_prog = ralloc(NULL, struct gl_shader_program);
- v = new vec4_visitor(brw, c, NULL, shader_prog, NULL, NULL);
+ v = new register_coalesce_vec4_visitor(brw, c, shader_prog);
_mesa_init_vertex_program(ctx, &c->vp->program, GL_VERTEX_SHADER, 0);