svga: silence MSVC float/int assignment warnings

This commit is contained in:
Brian Paul 2012-10-16 17:54:37 -06:00
parent 200291e087
commit d21e6c87c0
2 changed files with 3 additions and 3 deletions

View file

@ -113,8 +113,8 @@ svga_get_paramf(struct pipe_screen *screen, enum pipe_capf param)
case PIPE_CAPF_MAX_TEXTURE_ANISOTROPY:
if(!sws->get_cap(sws, SVGA3D_DEVCAP_MAX_TEXTURE_ANISOTROPY, &result))
return 4.0;
return result.u;
return 4.0f;
return (float) result.u;
case PIPE_CAPF_MAX_TEXTURE_LOD_BIAS:
return 15.0;

View file

@ -666,7 +666,7 @@ create_arl_consts( struct svga_shader_emitter *emit )
unsigned idx = emit->nr_hw_float_const++;
float vals[4];
for (j = 0; j < 4 && (j + i) < emit->num_arl_consts; ++j) {
vals[j] = emit->arl_consts[i + j].number;
vals[j] = (float) emit->arl_consts[i + j].number;
emit->arl_consts[i + j].idx = idx;
switch (j) {
case 0: