Sign in to follow this  

Lighting the scene help

This topic is 3046 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi guys, Whats best way to light a scene today considering, 1 light or more lights/spot lights? Not lightmaps, I dont want to use them. Also, how to determine what lights need to be used for a geometry in a scene? Is there any pre computation or what techniques are usually used? Thanks for replys.

Share this post


Link to post
Share on other sites
Quote:

Whats best way to light a scene today considering, 1 light or more lights/spot lights?

What's the best way depends on your goal, as always. Nowadays deferred rendering which allows you to render multiple lights in a single pass is quite trendy. Still point, spot and directional lights are common.

As an example, at the moment I use deferred rending with up to 50 lights displayed concurrendly.


Quote:

Also, how to determine what lights need to be used for a geometry in a scene? Is there any pre computation or what techniques are usually used?

Light culling is as important as geometry culling, but it depends on your rendering architecture. I would suggest to start with an easy approach, i.e. get all lights inside X units around your camera, order them by distance and display the closest Y lights.

From here you could start to improve the light culling:
1. Add priorities to your lights, disable low prio lights in favour of high prio lights which are farer away.
2. When you use a portal engine try to add information gathered from visible portals to increase or decrease a priority of a light.
3. Don't just turn displayed lights on/off, try to fade them in and out to avoid pop-up artifacts.

Good luck :)

--
Ashaman

Share this post


Link to post
Share on other sites
Don't forget-- you can drop some more lights by frustum culling their bounding volumes. This makes the most sense in a deferred shading context, but you could theoretically use it to optimize light selection for a forward shader.

Share this post


Link to post
Share on other sites

This topic is 3046 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this