I am trying to create a day and night cycle with a custom sky I made. The problem is that the skylight wont update with it.
When I force recaptures of the skylight with the blueprint, the skylight will change abruptly and I rather want a smoother transition.
What are the options for a skylight that will change gradually the same with the sky.
Is it possible to blend between a few prebaked cubemaps? Is that possible with the skylight? Or should I use the ambient cubemap?
Is it a possibility to render a camera to texture every frame and use that with the skylight if that is possible? Or will that be too heavy?
thanks
Smoothly updating hasn’t been implemented yet, sorry. The sky light was designed around supporting but we just haven’t gotten to it yet. Both recapturing the scene and specifying a new cubemap to use for lighting with smooth transitions are planned.
is somewhat of a brute force approach to doing , but it works.
I have the following graph (attached) set to update the capture every 5 in-game minutes, can be changed to whatever value you like (I used 5 because I was running at 2 sec real time = 1 min game time for testing purposes). I placed in a function that update my settings on tick, but you can just attach directly to Tick and get the same results. Note that I check for less than zero, I do because when 24 hours is reached, I reset current minute to 0, so if the previous minute was 1438, the result would end up as -3 and will remain less than 5 from that point on never evaluating as true after running one full day.
Updating the captures on Tick made a noticeable difference in performance, dropping my framerate by up to 10 fps, so I decided to update on a delayed schedule to avoid . So long as you set the value low enough (5 min max), the visual impact is minor. If you are using a closer to real time scale I would go for 30 seconds to a minute (game time) between captures.
Hope that helps!
Great to hear, is something that is planned. I hope it will be soon, but meanwhile I have to find a workaround.
Thanks for the example , I am trying to make something similar, but the problem I run into is that the skylight seems to normalize the captured image.
At night the sky is very dark and only the stars are slightly illuminating the surroundings, but the skylight boosts the capture so much that it lights the environment like it is daylight.
Does somebody noticed something similar?
Couldn’t the system be made to allow materials in place of the cubemap texture? We’d be able to handle the lerping and such through the material system.
Holy molly talk about thread revival… but while we’re here, has the smooth transition been implemented yet?
I don’t think it has been implemented yet. But i hope it does soon enough.
Are there any updates on ?
Should have done a quick search before asking:
.unrealengine.com/latest/INT/BlueprintAPI/SkyLight/SetCubemapBlend/index.html
Oh, awesome! Thanks for that link, I didn’t know they added it either.
I hope it works in 4.8, since I’ll be stuck in that version until they fix a couple of bugs.
Soooo, fours on… any news on one?
Yes, three years ago: https://forums.unrealengine.com/development-discussion/rendering/17374-best-solution-for-dynamic-sky-with-skylight?p=548263#post548263
Is a real time solution for still on the cards that doesn’t cause the kind of hitch seen with using the Recapture Sky node?
Though not perfect, you can set skylight intensity in tick according to timeofday instead of costly recapture.