Archived

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

HoDo

Lights in Landscape

Recommended Posts

HoDo    122
Chris, some time ago you posted this as a way to get lighting in the landscape. I changed this as you suggested but can''t see the light. Any thing else I can do? Search for UpdateMaterial in levelload.c. You''ll see where it sets the rendering method for the terrain materials. Change T_TEX_MODULATE to T_GOURTEX_MODULATE and it will use lighting. You can probably add point lights with this, along with ambient lighting. However the normals of all terrain vertices are set to (0,1,0) so directional lighting will not be correct. You can probably change the color equally over the entire terrain to make a decent day night cycle using this technique. Chris

Share this post


Link to post
Share on other sites
ChrisE    184
Guess it doesn''t work then. I won''t have an answer until I give it a try myself. The new landscape engine was never intended to have dynamic hardware lighting since the shadows are baked into the terrain texture.

Share this post


Link to post
Share on other sites
iram    122
Chris,

i think the shadow can still remain.

what i need is to be able to darken the terrain dynamically.
if you make it dark, then the shadow cannot be seen, which is correct.

i miss the old terrain where i fire a missile with light and you can see a round spot of light moving when the missile flies across.

Share this post


Link to post
Share on other sites