summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2012-10-16 17:54:37 -0600
committerBrian Paul <[email protected]>2012-10-16 17:55:39 -0600
commitd21e6c87c026015e395ee0f2b18ba4041c6773d6 (patch)
tree7ed8bf3502c88205c875861612776b2d73ded607 /src/gallium
parent200291e087f4b8ce33133cd245bc391b5c9f1fec (diff)
svga: silence MSVC float/int assignment warnings
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/svga/svga_screen.c4
-rw-r--r--src/gallium/drivers/svga/svga_tgsi_insn.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/gallium/drivers/svga/svga_screen.c b/src/gallium/drivers/svga/svga_screen.c
index ef285a9b7ff..4f7970df45c 100644
--- a/src/gallium/drivers/svga/svga_screen.c
+++ b/src/gallium/drivers/svga/svga_screen.c
@@ -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;
diff --git a/src/gallium/drivers/svga/svga_tgsi_insn.c b/src/gallium/drivers/svga/svga_tgsi_insn.c
index 2288a534b08..36ed0089fba 100644
--- a/src/gallium/drivers/svga/svga_tgsi_insn.c
+++ b/src/gallium/drivers/svga/svga_tgsi_insn.c
@@ -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: