Archived

This topic is now archived and is closed to further replies.

guppy

A question of lights....

Recommended Posts

A friend and I have been having an argument - and I though I''d bring it here for some help... Apperantly DirectX can have an infinit number of ligth scources in the active sceen (what you see), but OpenGL specs gives only 8... now the question is this - Is there no way you can have more ligth scources in your view with OpenGL (by an GL extension or some such)? --- Now you migth wonder why I would be so greedy as to need more than 8 ligths, well apart from finaly proving that to my friend that DX is evil and OpenGL is good! I could easily imagine a situation that would call for more ligths - a long street at nigth with all the street ligths on.... /Please excuse my bad spelling - My native language is binary not english \Take my advice - I don''''t use it...

Share this post


Link to post
Share on other sites
quote:
Original post by guppy
Apperantly DirectX can have an infinit number of ligth scources in the active sceen (what you see), but OpenGL specs gives only 8...



Not true..someone correct me if I''m wrong, but I believe in OpenGL its 8 lights per vertex , not scene.

Share this post


Link to post
Share on other sites
It''s not 8 lights per vertex, it''s 8 lights per glBegin/glEnd call. Anyway, I doubt that there are any video cards that can do more than 8 lights in hardware so it doesn''t really matter.....

ps: opengl doesn''t know what a ''scene'' is. It''s an IMMEDIATE mode api

Share this post


Link to post
Share on other sites
All consumer level cards support 8 lights at a time in hardware. Many professional grade cards support more. Both gl and dx will let you use as many lights as the card supports. You can always render an object with the closest 8 lights, change lights, and render the next object should your scene have more than 8 lights. Of course, most games still use light maps because it looks better than interpolated vertex lighting anyways.

Share this post


Link to post
Share on other sites
Well that settles it then

Thanks for shedding light on the case!

(phun intended)

/Please excuse my bad spelling - My native language is binary not english
\Take my advice - I don''''t use it...

Share this post


Link to post
Share on other sites