Original Post
Hi !
I''m doing lightmaps for my engine. I''ve implemented a shadow cast alogrithm. Now I want to put the Labert lighting of OpenGL into my lightmap. I can calculate it for each vertex, but I have problems with the interpolation. I have the world coordinates for my current lumel in the lightmap and I have the normals, world coordinates and normals for each vertex.
To do Goraud shadinf I have to interpolate between the three Labert light values for each vertex, I don''t want to calculate the distances with square roots, something that is faster would be good!
Any ideas ???
Tim