summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_context.c
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-03-10 10:56:06 -0700
committerBrian <[email protected]>2007-03-10 10:56:06 -0700
commit1fcb4ecc07685872c9c42569ba13faa1cad54d3c (patch)
tree68c7b7ae4e743f78341869d6081bdabadc05f68e /src/mesa/swrast/s_context.c
parentc9872b80c874ce7891c6b07c2d4f2fe099fdd8cd (diff)
clean-up formatting
Diffstat (limited to 'src/mesa/swrast/s_context.c')
-rw-r--r--src/mesa/swrast/s_context.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/src/mesa/swrast/s_context.c b/src/mesa/swrast/s_context.c
index 031d74f31b0..8864c217a5e 100644
--- a/src/mesa/swrast/s_context.c
+++ b/src/mesa/swrast/s_context.c
@@ -125,27 +125,28 @@ _swrast_update_rasterflags( GLcontext *ctx )
static void
_swrast_update_polygon( GLcontext *ctx )
{
- GLfloat backface_sign = 1;
+ GLfloat backface_sign;
if (ctx->Polygon.CullFlag) {
- backface_sign = 1;
- switch(ctx->Polygon.CullFaceMode) {
+ backface_sign = 1.0;
+ switch (ctx->Polygon.CullFaceMode) {
case GL_BACK:
- if(ctx->Polygon.FrontFace==GL_CCW)
- backface_sign = -1;
+ if (ctx->Polygon.FrontFace == GL_CCW)
+ backface_sign = -1.0;
break;
case GL_FRONT:
- if(ctx->Polygon.FrontFace!=GL_CCW)
- backface_sign = -1;
+ if (ctx->Polygon.FrontFace != GL_CCW)
+ backface_sign = -1.0;
break;
- default:
case GL_FRONT_AND_BACK:
- backface_sign = 0;
+ /* fallthrough */
+ default:
+ backface_sign = 0.0;
break;
}
}
else {
- backface_sign = 0;
+ backface_sign = 0.0;
}
SWRAST_CONTEXT(ctx)->_BackfaceSign = backface_sign;