Sun Cycles
by JohnT · in Torque X 2D · 05/06/2008 (6:58 am) · 4 replies
I am working on adding dynamic exterior lighting to my scene and just realized that the terrain already had a flag that can be set to make it adjustable based upon the sun lighting level.
Add to TerrainData
true
Since that was already available I thought I'd look around the source code for the skybox but unfortunately I'm not coming up with anything easy this time to adjust the material for the sky.
Any ideas?
Add to TerrainData
Since that was already available I thought I'd look around the source code for the skybox but unfortunately I'm not coming up with anything easy this time to adjust the material for the sky.
Any ideas?
About the author
#2
From what I can tell about the terrain lighting it only adjusts the overall ambient light level of the terrain and shadows are painted on the texture map for the terrain and do not move with the suns position. I have not looked into this recently but I'm wondering if there is a way to use the blob shadow instead to give a better effect.
If by chance you can find the skybox project online I would definitely like to see it
Thanks,
John
06/15/2008 (11:24 am)
Scott,From what I can tell about the terrain lighting it only adjusts the overall ambient light level of the terrain and shadows are painted on the texture map for the terrain and do not move with the suns position. I have not looked into this recently but I'm wondering if there is a way to use the blob shadow instead to give a better effect.
If by chance you can find the skybox project online I would definitely like to see it
Thanks,
John
#3
Finally found that sky box...
http://www.codeplex.com/XNACommunity/Wiki/View.aspx?title=Componente%20SkyDome
I haven't tried plugging it into Torque yet but it does look pretty nice in action.
06/15/2008 (1:19 pm)
I'm trying to generate a random terrain and get it lit at the start of a level including shadows from static geometry. I'm guessing I'll have to dive into the source a bit more to see what's going on but I don't really have much of a clue about the inner workings of Torque yet. Finally found that sky box...
http://www.codeplex.com/XNACommunity/Wiki/View.aspx?title=Componente%20SkyDome
I haven't tried plugging it into Torque yet but it does look pretty nice in action.
#4
Thanks!
06/15/2008 (1:30 pm)
Wow, the sky cycles looks great! I cannot wait to see the L3DT terrains in the next release and try and integrate that code. Thanks!
Torque Owner luggage
A quick question - I've tried adding the lightenabled into my terrain data but it doesn't look like it's lit from the sun. Is there anything else I need to do? I'm using the FPSDemo as a starter point for my game.
I did see an XNA Skybox that had atmospheric scattering implemented in the shader I believe. The sun would move across the sky and as it got to sun set\sun rise the sky colour would change. If I find it I'll point you in the right direction if that's the kind of thing you're looking for.
Thanks.
Scott