NeedEyeCoords if non-uniform scale transform
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
/* $Id: state.c,v 1.20 2000/06/27 04:33:59 brianp Exp $ */
|
/* $Id: state.c,v 1.21 2000/06/30 14:14:37 brianp Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Mesa 3-D graphics library
|
* Mesa 3-D graphics library
|
||||||
@@ -1177,8 +1177,12 @@ void gl_update_state( GLcontext *ctx )
|
|||||||
ctx->NeedEyeNormals = GL_FALSE;
|
ctx->NeedEyeNormals = GL_FALSE;
|
||||||
|
|
||||||
if (ctx->Light.Enabled) {
|
if (ctx->Light.Enabled) {
|
||||||
if ((ctx->Light.Flags & LIGHT_POSITIONAL) || ctx->Light.NeedVertices){
|
if ((ctx->Light.Flags & LIGHT_POSITIONAL) ||
|
||||||
/* Need length for attenuation or need angle for spotlights */
|
ctx->Light.NeedVertices ||
|
||||||
|
!TEST_MAT_FLAGS( &ctx->ModelView, MAT_FLAGS_LENGTH_PRESERVING)) {
|
||||||
|
/* Need length for attenuation or need angle for spotlights
|
||||||
|
* or non-uniform scale matrix
|
||||||
|
*/
|
||||||
ctx->NeedEyeCoords = GL_TRUE;
|
ctx->NeedEyeCoords = GL_TRUE;
|
||||||
}
|
}
|
||||||
ctx->NeedEyeNormals = ctx->NeedEyeCoords;
|
ctx->NeedEyeNormals = ctx->NeedEyeCoords;
|
||||||
|
Reference in New Issue
Block a user