intel: Fix warnings from gl_constant_parameter changes.
authorEric Anholt <eric@anholt.net>
Fri, 5 Aug 2011 19:47:25 +0000 (12:47 -0700)
committerEric Anholt <eric@anholt.net>
Fri, 5 Aug 2011 19:56:12 +0000 (12:56 -0700)
src/mesa/drivers/dri/i915/i915_fragprog.c
src/mesa/drivers/dri/i965/brw_wm_fp.c
src/mesa/drivers/dri/i965/brw_wm_pass0.c

index 32050cebf3366e4559a5034a07ccdd9c40154248..d155b85ffca4ffa6fe2e566010aeca1dd06bc47e 100644 (file)
@@ -175,10 +175,8 @@ src_vector(struct i915_fragment_program *p,
    case PROGRAM_STATE_VAR:
    case PROGRAM_NAMED_PARAM:
    case PROGRAM_UNIFORM:
-      src =
-         i915_emit_param4fv(p,
-                            program->Base.Parameters->ParameterValues[source->
-                                                                      Index]);
+      src = i915_emit_param4fv(p,
+        &program->Base.Parameters->ParameterValues[source->Index][0].f);
       break;
 
    default:
index 7cd3edad23588d52fbd9448cce6d77b1a017d70e..d52a9581f5e9026734aea96352907f21d2dad419 100644 (file)
@@ -535,15 +535,15 @@ static struct prog_src_register search_or_add_const4f( struct brw_wm_compile *c,
                                                     GLfloat s3)
 {
    struct gl_program_parameter_list *paramList = c->fp->program.Base.Parameters;
-   GLfloat values[4];
+   gl_constant_value values[4];
    GLuint idx;
    GLuint swizzle;
    struct prog_src_register reg;
 
-   values[0] = s0;
-   values[1] = s1;
-   values[2] = s2;
-   values[3] = s3;
+   values[0].f = s0;
+   values[1].f = s1;
+   values[2].f = s2;
+   values[3].f = s3;
 
    idx = _mesa_add_unnamed_constant( paramList, values, 4, &swizzle );
    reg = src_reg(PROGRAM_STATE_VAR, idx);
index f78bdc31866c576a67aa815b8be66935871e0534..ccf9dc2bc18f899ac9cbe872b60f6f4ec3432509 100644 (file)
@@ -205,14 +205,14 @@ static const struct brw_wm_ref *pass0_get_reg( struct brw_wm_compile *c,
         case PROGRAM_CONSTANT:
            /* These are invarient:
             */
-           ref = get_const_ref(c, &plist->ParameterValues[idx][component]);
+           ref = get_const_ref(c, &plist->ParameterValues[idx][component].f);
            break;
 
         case PROGRAM_STATE_VAR:
         case PROGRAM_UNIFORM:
            /* These may change from run to run:
             */
-           ref = get_param_ref(c, &plist->ParameterValues[idx][component] );
+           ref = get_param_ref(c, &plist->ParameterValues[idx][component].f );
            break;
 
         default: