i965: Remove brw_shader_program wrapper struct.
authorKenneth Graunke <kenneth@whitecape.org>
Wed, 14 Nov 2012 03:59:08 +0000 (19:59 -0800)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 15 Nov 2012 19:14:34 +0000 (11:14 -0800)
At this point, it's just gl_shader_program.  Nobody even uses it; even
the program that creates them only returns gl_shader_program pointers.

Reviewed-by: Eric Anholt <eric@anholt.net>
src/mesa/drivers/dri/i965/brw_context.h
src/mesa/drivers/dri/i965/brw_shader.cpp

index 3911b22088c47bed008dbaeda3b2b724f5b19b1d..49460e9f3cd0517ecfd9959a9eee415e1d843a71 100644 (file)
@@ -280,10 +280,6 @@ struct brw_shader {
    struct exec_list *ir;
 };
 
-struct brw_shader_program {
-   struct gl_shader_program base;
-};
-
 /* Data about a particular attempt to compile a program.  Note that
  * there can be many of these, each in a different GL state
  * corresponding to a different brw_wm_prog_key struct, with different
index f8482e1695c4cce857daeea56e6ed86602a3211d..005779da9d9709f3b89c3ea8282cc63d4bb7583e 100644 (file)
@@ -48,13 +48,12 @@ brw_new_shader(struct gl_context *ctx, GLuint name, GLuint type)
 struct gl_shader_program *
 brw_new_shader_program(struct gl_context *ctx, GLuint name)
 {
-   struct brw_shader_program *prog;
-   prog = rzalloc(NULL, struct brw_shader_program);
+   struct gl_shader_program *prog = rzalloc(NULL, struct gl_shader_program);
    if (prog) {
-      prog->base.Name = name;
-      _mesa_init_shader_program(ctx, &prog->base);
+      prog->Name = name;
+      _mesa_init_shader_program(ctx, prog);
    }
-   return &prog->base;
+   return prog;
 }
 
 /**