Changing sky color

Hello.
I need to make a SkyBox (or somethign else) which allows me to change the color of the sky when I want in my code.

I tried this but it needs a texture.

Anyone knows how I should proceed ?

Thank you

If you’re just wanting a solid color, this method works well:

viewPort.setBackgroundColor(ColorRGBA.White);

1 Like

Works well thanks !

I managed to get a cool render for a sunrise and sunset but I can’t really do it.
So what I need is a way to set a sky texture which would allow me to make a sunrise effect.

Is there something which already works for that or should I start to code my own class to do that?
Wether, should I use the SkyFactory class as good start?

Thank you.

Yes, please look at the manual for sky boxes.
The content of this post is meant to be read as a straight information or question without an implicit dismissive stance or interest in having the other party feel offended unless theres emotes that hint otherwise or theres an increased use of exclamation marks and all-capital words.

Ok, so I saw the Preload method.
For a sunris effect should I preload multiple textures and load them progressively ?

I think this should be nice for setting a good sky but what for animate it ?

A sky shader. Search the forum, theres been a lot of implementations already.
The content of this post is meant to be read as a straight information or question without an implicit dismissive stance or interest in having the other party feel offended unless theres emotes that hint otherwise or theres an increased use of exclamation marks and all-capital words.