what if I want to create such a background in the scene
Hello and welcome!
The simplest way is to set canvas transparent with
scene.clearColor = new BABYLON.Color4(0,0,0,0);
and use any CSS background behind the canvas.
Example: Mu-so Wood Edition 3D
Please note, that this is just background, it is not a texture.
For textures one may use Color3Gradient | Babylon.js Documentation
4 Likes
Just to add you can also use layers
https://www.babylonjs-playground.com/#2U7D0U
or create a cube map
3 Likes
You can also set the clearColor to transparent, and do a CSS gradient on the canvas parent node
1 Like
nice thanks