8 light limit

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Post Reply
omaremad
Competition winner
Posts: 1027
Joined: Fri Jul 15, 2005 11:30 pm
Location: Cairo,Egypt

8 light limit

Post by omaremad »

i heard niko overcome the 8 light limit
does any one have some code please
eXodus
Posts: 320
Joined: Tue Jan 04, 2005 10:07 am
Location: Canada
Contact:

Post by eXodus »

DirectX permits 8 lights at the same time, which is probably more than enough.

Maybe its different with the software rasterizer.
omaremad
Competition winner
Posts: 1027
Joined: Fri Jul 15, 2005 11:30 pm
Location: Cairo,Egypt

Post by omaremad »

for small scale yes but if each room has its own light?

im using a lot of normal maps thats why
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

simplest way would probably be to add the lights in to the quad tree node that was posted in the project announcements forum.
you could go one further and sort the visible lights by brightness and distance from the camera, and just keep the top 8
genesisrage
Posts: 93
Joined: Tue Feb 08, 2005 12:19 pm

Post by genesisrage »

i keep hearing everyone say 8 lights is enough... but im having a HUGE problem trying to find out when 8 light would be enough...

for a game like Doom3 1 light is enough :)
but one thing ive been trying to find out for a long time, what if you want a large room with 10 lights on each side wall... and give off dynamic shadows... but you can shoot the lights out and they go dark... and you have a plasma sci-fi gun where the bullets have a glow that lights up around them... and you can shoot 10 bullets in one second...

granted this example is a little more elaborate than one might need... but for a sci-fi shooter this is something that you would very likely see. there is a hundred examples i could think of that 8 lights would never be enough. i know hardware lighting takes a lot of computer power to do, but i know many games out there have ways of doing this. i know they arent using DX lights, but what options do we have to create that many dynamic lights?

and if anyone out there has actually done something that acts as if there were more than 8 dynamic lights it would be awesome if you could "share the wealth"
omaremad
Competition winner
Posts: 1027
Joined: Fri Jul 15, 2005 11:30 pm
Location: Cairo,Egypt

Post by omaremad »

these are software lights niko said he made them work but will be in the next release
Midnight
Posts: 1772
Joined: Fri Jul 02, 2004 2:37 pm
Location: Wonderland

Post by Midnight »

you wouldn't want to have that much light in a multiplayer FPS anyways it would cause major slow down...

however in an rpg or something thats another story lighting is key.
Murphy
Posts: 290
Joined: Mon Dec 13, 2004 12:06 am
Location: United States
Contact:

Post by Murphy »

genesisrage wrote:and you have a plasma sci-fi gun where the bullets have a glow that lights up around them... and you can shoot 10 bullets in one second...
In Quake 2 and 3, for example, this is done using what is basically lightmapping. The glows don't cast shadows, but then... there's only just so much computing power per frame. :)
VeneX
Posts: 228
Joined: Sun Nov 30, 2003 3:32 pm
Location: The Netherlands
Contact:

Post by VeneX »

heared Niko talking about 500 dynamic lights
http://irrlicht.sourceforge.net/phpBB2/ ... =500#48064
Visit my website @ www.venex.be
Plethora project will be added to the site
AMD AthlonXP 2600+, 512MB DDR, Radeon M10 (mobile 9600) PRO 64MB, WinXP
elander
Posts: 193
Joined: Tue Oct 05, 2004 11:37 am

Post by elander »

I think you can have as many lights as you want if you implement your own lighting model with shaders and pass on the closest light positions to the shaders, but as in everything this means a greater performance cost.

About Doom3 i believe there no lights at all in that game. The stuff you use in the game, the flashlight is actualy done with a shader and the flickering lights, i belive are some sort of clever lightmap animation trick.
Post Reply