Page 1 of 1
how do you imagine to make this?
Posted: Fri Oct 21, 2011 6:31 pm
by Nahuel
http://www.youtube.com/watch?v=METuciFfBKQ
1- the sky are two big speric models rotating ??
2- the sun is another model
3-the sunlight is a dinamic light??????????????
I do not know

it´s a great effect no doubt
Re: how do you imagine to make this?
Posted: Fri Oct 21, 2011 7:02 pm
by Spike
shadowmaps, so yes the sun is a dynamic light.
the sky could be coded in glsl easily enough. depends how easy it is to feed values to shaders in whatever engine you're using to get the sun in the right position. or you could use a sprite and skyroom.
Re: how do you imagine to make this?
Posted: Fri Oct 21, 2011 11:41 pm
by mh
The sky could be done with 3 cubemaps.
The first (furthest back) one has clouds and rotates the texture matrix. Likewise the second (middle). The third (frontmost) has alpha 0 in the source images where the clouds should show. No need for rotating spheres drawn at a distance, this can be done directly on the original world geometry. The cloud layers needn't be high-res - clouds are pretty fuzzy anyway so a 256-size cubemap may even be enough; the mountains layer can be as high-res as your hardware can take. One pass in a shader (that could also include brightness factors, as well as other properties to make it look cooler). You could even go nuts and have many more layers, if your hardware was up to the job of running it. Blend between 2 "day layers" and 2 "night layers" for the clouds, then add in the frontmost/mountains layer with a fade to black/night colour. Nice day/night cycles.
It may even be possible to do without shaders, if you're comfortable with setting up texture combine modes, but any hardware that's capable of it would probably also be capable of shaders too, and shaders are just so much easier to do this kind of thing with.
Re: how do you imagine to make this?
Posted: Sat Oct 22, 2011 1:29 am
by Nahuel
Spike and Mh
Thanks for your request. I do not know anything about the use of shaders like that. Do you know where can i find and example of this??
How is possible blending cubemaps or rotate it??
Thanks in advance!!

Re: how do you imagine to make this?
Posted: Mon Oct 24, 2011 2:23 pm
by Irritant
We've already done that sky effect in Alien Arena. Not really that hard to do.
Re: how do you imagine to make this?
Posted: Tue Oct 25, 2011 7:35 am
by leileilol
i've done this exact thing in darkplaces before. I'll have to dig up the test with it
Re: how do you imagine to make this?
Posted: Tue Oct 25, 2011 6:33 pm
by goldenboy
Moving/rotating sky images *only* make sense when the sun itself is dynamic, and if the sunlight direction matches the actual image of the sun at all times. Otherwise you have the sun disk on one side, but the light coming from the other - that would suck from a level design perspective.
Re: how do you imagine to make this?
Posted: Wed Oct 26, 2011 2:43 pm
by mh
You could have a static sun layer but a moving clouds layer. You could also store some info in the alpha channel of the clouds layer that affects how the clouds are affected by sunlight, rotate RGB, leave A static and get a nice effect.