View Full Version : Rendering lightmaps

07-22-2001, 02:48 AM
Hi, I've just implemented a lightmap calulator and rendering them, in my engine. The problem is, that when I use a filter other than GL_NEAREST (which looks like crap, as we all know), I get artefacts at the edges of my polygons. What I think is happening, is that the bi-linear filter is wrapping the egdes around for its filturing calculations. So if I have a poly that goes from bright to dark, and I render it with GL_LINEAR or GL_LINEAR_MIPMAP_LINEAR, on the dark side, on the edge, there is a light line, on the light side, there is a dark line.
Although this is only a small error, and sometimes not noticable, I would like to know if there is a way to render them without introducing stupid errors like that.

Thanks in advance, Danny Lousberg

07-22-2001, 04:34 AM
Try this thread (http://www.opengl.org/discussion_boards/ubb/Forum3/HTML/003070.html) .

07-22-2001, 05:22 AM
Thanx man, that helped a lot. http://www.opengl.org/discussion_boards/ubb/smile.gif