i965: add casts to silence int/enum conversion warnings
authorBrian Paul <brianp@vmware.com>
Tue, 6 Sep 2011 22:50:27 +0000 (16:50 -0600)
committerBrian Paul <brianp@vmware.com>
Tue, 6 Sep 2011 22:50:27 +0000 (16:50 -0600)
src/mesa/drivers/dri/i965/brw_fs.cpp

index 1f3d9d868ddd0c5e8e788b08799d100e0e4a3b85..7f5194b06ed0797a9f40ec9d6585c4f7165038c3 100644 (file)
@@ -672,7 +672,7 @@ fs_visitor::calculate_urb_setup()
       /* FINISHME: The sf doesn't map VS->FS inputs for us very well. */
       for (unsigned int i = 0; i < VERT_RESULT_MAX; i++) {
         if (c->key.vp_outputs_written & BITFIELD64_BIT(i)) {
-           int fp_index = _mesa_vert_result_to_frag_attrib(i);
+           int fp_index = _mesa_vert_result_to_frag_attrib((gl_vert_result) i);
 
            if (fp_index >= 0)
               urb_setup[fp_index] = urb_next++;
@@ -1826,7 +1826,7 @@ brw_fs_precompile(struct gl_context *ctx, struct gl_shader_program *prog)
 
       key.proj_attrib_mask |= 1 << i;
 
-      int vp_index = _mesa_vert_result_to_frag_attrib(i);
+      int vp_index = _mesa_vert_result_to_frag_attrib((gl_vert_result) i);
 
       if (vp_index >= 0)
         key.vp_outputs_written |= BITFIELD64_BIT(vp_index);