aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/tnl/t_vb_light.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2001-01-29 22:10:24 +0000
committerBrian Paul <[email protected]>2001-01-29 22:10:24 +0000
commit184a575a00a7d325454bff8f352ab0f407ff19b1 (patch)
tree671df555bb32f07ba52a2ba0ed134fabcd7dbb09 /src/mesa/tnl/t_vb_light.c
parent407b487017a5c5a213f399ec1667fe2aa7ed340d (diff)
only compute separate specular if texturing really enabled
Diffstat (limited to 'src/mesa/tnl/t_vb_light.c')
-rw-r--r--src/mesa/tnl/t_vb_light.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/mesa/tnl/t_vb_light.c b/src/mesa/tnl/t_vb_light.c
index a4f7cfa3c31..13ab9a395ba 100644
--- a/src/mesa/tnl/t_vb_light.c
+++ b/src/mesa/tnl/t_vb_light.c
@@ -1,4 +1,4 @@
-/* $Id: t_vb_light.c,v 1.5 2001/01/24 00:04:59 brianp Exp $ */
+/* $Id: t_vb_light.c,v 1.6 2001/01/29 22:10:24 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -170,7 +170,8 @@ static GLboolean run_validate_lighting( GLcontext *ctx,
if (ctx->Visual.rgbMode) {
if (ctx->Light._NeedVertices) {
- if (ctx->Light.Model.ColorControl==GL_SEPARATE_SPECULAR_COLOR)
+ if (ctx->Light.Model.ColorControl == GL_SEPARATE_SPECULAR_COLOR &&
+ ctx->Texture._ReallyEnabled)
tab = _tnl_light_spec_tab;
else
tab = _tnl_light_tab;
@@ -267,7 +268,8 @@ static void check_lighting( GLcontext *ctx, struct gl_pipeline_stage *stage )
stage->inputs |= VERT_RGBA;
stage->outputs = VERT_RGBA;
- if (ctx->Light.Model.ColorControl == GL_SEPARATE_SPECULAR_COLOR)
+ if (ctx->Light.Model.ColorControl == GL_SEPARATE_SPECULAR_COLOR &&
+ ctx->Texture._ReallyEnabled)
stage->outputs |= VERT_SPEC_RGB;
}
}