scaling affect the lighting on object??

i m trying to do scaling on object …where GL_LIGHTING is enabled …scaling changes the color and its apperance …

plz tell me how to rectify dis prob

You are probably using glScalef command which will also scale your normals. If you are using a shader then ensure you renormalise them on the vertex shader. For fixed function rendering you can use glEnable (GL_NORMALIZE)

Even using fixed function pipeline, rescaling normals generates some odd results.
Enable GL_NORMALIZE and be happy.

If you scale differently in x, y and z, then it is not enough to renormalize using GL_NORMALIZE (except when normals are parallel to scaling axis). I think GL_RESCALE_NORMAL can handle this?

I think that’s backwards. RESCALE_NORMAL handles uniform scales. NORMALIZE handles that and non-uniform scales as well.

thanks alot glEnable (GL_NORMALIZE) works good