r300-gallium: Fix build errors.
authorCorbin Simpson <MostAwesomeDude@gmail.com>
Fri, 13 Feb 2009 04:35:17 +0000 (20:35 -0800)
committerCorbin Simpson <MostAwesomeDude@gmail.com>
Fri, 13 Feb 2009 04:35:17 +0000 (20:35 -0800)
src/gallium/drivers/r300/r300_emit.c
src/gallium/drivers/r300/r300_state_shader.h
src/gallium/drivers/r300/r300_surface.c

index a4d520a67411bb4e8441d24dc1725cbc1de88152..a3b2772e155f69821ff60f1f1668d14a59bf0b9c 100644 (file)
@@ -115,7 +115,7 @@ void r500_emit_fragment_shader(struct r300_context* r300,
 {
     CS_LOCALS(r300);
     int i = 0;
-    BEGIN_CS(11 + (shader->shader.instruction_count * 6));
+    BEGIN_CS(11 + (fs->instruction_count * 6));
     OUT_CS_REG(R500_US_CONFIG, R500_ZERO_TIMES_ANYTHING_EQUALS_ZERO);
     OUT_CS_REG(R500_US_PIXSIZE, fs->shader.stack_size);
     OUT_CS_REG(R500_US_CODE_ADDR, R500_US_CODE_START_ADDR(0) |
@@ -123,14 +123,14 @@ void r500_emit_fragment_shader(struct r300_context* r300,
 
     OUT_CS_REG(R500_GA_US_VECTOR_INDEX, R500_GA_US_VECTOR_INDEX_TYPE_INSTR);
     OUT_CS_ONE_REG(R500_GA_US_VECTOR_DATA,
-        shader->shader.instruction_count * 6);
-    for (i = 0; i < shader->shader.instruction_count; i++) {
-        OUT_CS(shader->instructions[i].inst0);
-        OUT_CS(shader->instructions[i].inst1);
-        OUT_CS(shader->instructions[i].inst2);
-        OUT_CS(shader->instructions[i].inst3);
-        OUT_CS(shader->instructions[i].inst4);
-        OUT_CS(shader->instructions[i].inst5);
+        fs->instruction_count * 6);
+    for (i = 0; i < fs->instruction_count; i++) {
+        OUT_CS(fs->instructions[i].inst0);
+        OUT_CS(fs->instructions[i].inst1);
+        OUT_CS(fs->instructions[i].inst2);
+        OUT_CS(fs->instructions[i].inst3);
+        OUT_CS(fs->instructions[i].inst4);
+        OUT_CS(fs->instructions[i].inst5);
     }
     R300_PACIFY;
     END_CS;
index 8e9ed5d59e01752763cc6a15c3e5d61c46ddea98..a5f03b967b30ccded3e459eab48b22670ccd153d 100644 (file)
@@ -47,16 +47,16 @@ static const struct r300_fragment_shader r300_passthrough_fragment_shader = {
     OUT_CS(R300_US_OUT_FMT_UNUSED);
     OUT_CS(R300_US_OUT_FMT_UNUSED);
     OUT_CS_REG(R300_US_W_FMT, R300_W_FMT_W0); */
-    .alu_instruction_count = 1;
-    .tex_instruction_count = 0;
-    .indirections = 1;
-    .shader.stack_size = 2;
+    .alu_instruction_count = 1,
+    .tex_instruction_count = 0,
+    .indirections = 1,
+    .shader.stack_size = 2,
 
     /* XXX decode these */
-    .instructions[0].alu_rgb_inst = 0x50A80;
-    .instructions[0].alu_rgb_inst = 0x1C000000;
-    .instructions[0].alu_alpha_inst = 0x40889;
-    .instructions[0].alu_alpha_inst = 0x1000000;
+    .instructions[0].alu_rgb_inst = 0x50A80,
+    .instructions[0].alu_rgb_inst = 0x1C000000,
+    .instructions[0].alu_alpha_inst = 0x40889,
+    .instructions[0].alu_alpha_inst = 0x1000000,
 };
 
 static const struct r500_fragment_shader r500_passthrough_fragment_shader = {
index 2c6af363f285f00f7bf461c4d3061c1fb6ecb2ad..7a4114554b5b959ea9a97be76248b06e7988bf76 100644 (file)
@@ -234,7 +234,7 @@ static void r300_surface_fill(struct pipe_context* pipe,
     } else {
         r300_emit_fragment_shader(r300, &r300_passthrough_fragment_shader);
     }
-    
+
     BEGIN_CS(2 + (caps->has_tcl ? 23 : 2));
     /* XXX these magic numbers should be explained when
      * this becomes a cached state object */