diff options
author | Brian Paul <[email protected]> | 2008-07-29 17:43:35 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2008-07-29 17:43:35 -0600 |
commit | 016701f6860a840e079cb4c5f844a8cced712cd8 (patch) | |
tree | 217bbdbb61654ebf06220b19ecca7388024076c0 /src/mesa/shader/prog_statevars.c | |
parent | b26a80aa12f1f8316da495b4fdeb94e75ba5d740 (diff) |
mesa: Silence compiler warnings on Windows.
Diffstat (limited to 'src/mesa/shader/prog_statevars.c')
-rw-r--r-- | src/mesa/shader/prog_statevars.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mesa/shader/prog_statevars.c b/src/mesa/shader/prog_statevars.c index e446e1c4197..91392650a36 100644 --- a/src/mesa/shader/prog_statevars.c +++ b/src/mesa/shader/prog_statevars.c @@ -254,7 +254,7 @@ _mesa_fetch_state(GLcontext *ctx, const gl_state_index state[], value[1] = ctx->Fog.Start; value[2] = ctx->Fog.End; value[3] = (ctx->Fog.End == ctx->Fog.Start) - ? 1.0 : 1.0F / (ctx->Fog.End - ctx->Fog.Start); + ? 1.0f : (GLfloat)(1.0 / (ctx->Fog.End - ctx->Fog.Start)); return; case STATE_CLIPPLANE: { @@ -410,9 +410,9 @@ _mesa_fetch_state(GLcontext *ctx, const gl_state_index state[], = ctx->Texture.Unit[unit]._Current; if (texObj) { struct gl_texture_image *texImage = texObj->Image[0][0]; - ASSIGN_4V(value, 1.0 / texImage->Width, - 1.0 / texImage->Height, - 0.0, 1.0); + ASSIGN_4V(value, (GLfloat) (1.0 / texImage->Width), + (GLfloat)(1.0 / texImage->Height), + 0.0f, 1.0f); } } return; @@ -426,7 +426,7 @@ _mesa_fetch_state(GLcontext *ctx, const gl_state_index state[], * exp2: 2^-((density/(ln(2)^2) * fogcoord)^2) */ value[0] = (ctx->Fog.End == ctx->Fog.Start) - ? 1.0 : -1.0F / (ctx->Fog.End - ctx->Fog.Start); + ? 1.0f : (GLfloat)(-1.0F / (ctx->Fog.End - ctx->Fog.Start)); value[1] = ctx->Fog.End * -value[0]; value[2] = ctx->Fog.Density * ONE_DIV_LN2; value[3] = ctx->Fog.Density * ONE_DIV_SQRT_LN2; |