Falagard
02-06-2006 21:35:13
Tuan, questions about lighting the terrain dynamically.
My requirements are:
1. Works on older cards without vertex shader or pixel shader support
2. Some dynamic lights for things like street lights or campfires.
3. Supports day/night cycle (this one could simply mean supporting an ambient colour change - for example, lightmaps + ambient that changes throughout the day is reasonable)
4. The key factor is the terrain shouldn't look "flat" and have some shading, but it doesn't necessarily need to have the terrain cast shadows.
I've seen instant base texture, and I've also used the fixed function lighting when normals are turned on the terrain.
I need a solution that's going to work for older cards without vertex shader support, so I'm thinking of going with generating normals and having a version of the splatting shader that performs vertex lighting. I know that vertex lighting can look bad on terrain with LODs, but the fact is that I'm going to be having enough stuff in the view that the distant terrain probably won't even be visible very often.
The other possibility is lightmaps + some dynamic lighting. This one might even be the best solution.
Do you have any suggestions on the best way to do this? Another factor I guess is memory consumption, etc.
Clay
My requirements are:
1. Works on older cards without vertex shader or pixel shader support
2. Some dynamic lights for things like street lights or campfires.
3. Supports day/night cycle (this one could simply mean supporting an ambient colour change - for example, lightmaps + ambient that changes throughout the day is reasonable)
4. The key factor is the terrain shouldn't look "flat" and have some shading, but it doesn't necessarily need to have the terrain cast shadows.
I've seen instant base texture, and I've also used the fixed function lighting when normals are turned on the terrain.
I need a solution that's going to work for older cards without vertex shader support, so I'm thinking of going with generating normals and having a version of the splatting shader that performs vertex lighting. I know that vertex lighting can look bad on terrain with LODs, but the fact is that I'm going to be having enough stuff in the view that the distant terrain probably won't even be visible very often.
The other possibility is lightmaps + some dynamic lighting. This one might even be the best solution.
Do you have any suggestions on the best way to do this? Another factor I guess is memory consumption, etc.
Clay