Skip to main content
gamedev.net
🔒 Locked

Fast Lighting

Started by Jerec 3 replies 300+ views
Original Post
Jerec
Jerec
I''ve got a terrain for a top down shooting game (like Raiden), and at any given time approximately an area of about 128x128 verticies is visible (at highest quaility)... I would like to light the terrain as cheaply as possible... I have one directional light for the sun... after that, I have any number of point lights... hardware lighting for the sun would be impossible because I have simple vertex shadows... if anyone knows of any cheap lighting equations it''d be a great help... on a side note, is there even a way to mix hardware and software lighting on the same verticies? if I were to have a hardware directional light and software point lights on the same terrain mesh, for instance...
JerecCM Software"Oro?"
CraZeE
CraZeE
lightmaps for the sunlight?
To learn, we share... Give some to take some -
Jerec
Jerec
the sunlight and terrain shadows are 100% dynamic (with vertex lighting), so I can have a day/night cycle... lightmapped point lights would be nice... but I have no idea how to simulate point lighting with lightmaps...
JerecCM Software"Oro?"
MagicScript
MagicScript
You could generate three lightmaps: one for dawn, one for noon, and one for dusk. Then as the game progresses, interpolate between the appropriate two to determine the proper lighting at any exact mommnt. This assumes there will be some sort of fixed lighting during the night. If not, you could add a fourth lightmap for midnight. You could always add more lightmaps to increase the resolution of the timing.
Basiror
Basiror
quote:
Original post by MagicScript
You could generate three lightmaps: one for dawn, one for noon, and one for dusk. Then as the game progresses, interpolate between the appropriate two to determine the proper lighting at any exact mommnt. This assumes there will be some sort of fixed lighting during the night. If not, you could add a fourth lightmap for midnight. You could always add more lightmaps to increase the resolution of the timing.


funny you will have problems with large polycounts

because you will run out of memory

if you use lightmaps use luminance map and ogl lights for colors
http://www.8ung.at/basiror/theironcross.html

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.