Not logged in, Join Here! or Log In Below:  
 
News Articles Search    
 

 Home / 3D Theory & Graphics / Lighting in real time games Account Manager
 
Archive Notice: This thread is old and no longer active. It is here for reference purposes. This thread was created on an older version of the flipcode forums, before the site closed in 2005. Please keep that in mind as you view this thread, as many of the topics and opinions may be outdated.
 
neo2gl

April 07, 2005, 07:19 AM

Hi all,

I'm tring to design a 3D real time FPS game for OpenGL v1.X (a first time for me), and I'm tackling the issue of lighting. Lighting is computationally intense process, but since my models are still simple at this early stage, I cannot estimate how severe the performance penalty would be for using lights, that way or the other.

Some information about a typical scene, as I plan it to be:
* up to 8 dynamic lights, normally only ~3 per frame
* up to 100 static lights in world, up to ~10 per frame
* up to 10,000 polygons per frame (but only ~2,000 at start)

What is the best way, considering the trade off of computational overhead vs. user feel to make the light selection:
1. Per vertex lighting (glLight) for dynamic lights, lightmapping for static lights
2. Always use lightmapping (performance of dynamic lights?)
3. Always use per vertex lighting
4. Other?

How would my choice changes if I'd like to run it over older GPUs (GeForce 2)?
How is lighting implemented in games today and in the near past?

Thanks you!

 
Reedbeta

April 07, 2005, 01:17 PM

For lights that are static, absolutely use lightmapping. This is the only way you are going to possibly make a large number of lights work in real-time. And lightmapping lets you have radiosity for free (that is, free at run-time, but obviously requires more map compile time). You can then easily blend in dynamic lights, done using shaders, or on older hardware ARB combiners and/or nVIDIA register combiners. I'd recommend against using vertex lighting at all as it looks crappy unless you have very highly tesselated models (it might be good for monsters and things, but not for lighting the world).

 
neo2gl

April 08, 2005, 01:11 PM

Thanks!
Your tip is much helpful! I will look into it.

 
This thread contains 3 messages.
 
 
Hosting by Solid Eight Studios, maker of PhotoTangler Collage Maker.