I need to be able to assing new textures to a skybox faces at runtime because the scenery can change to an arbitrary number possible backgrounds queried on the fly remotly. I need in fact to do the same job as the skybox editor once you set the shader to RenderFX/Skybox
It seems that internal properties of RenderFX/Skybox are not accessible
Skybox sb=this.camera.GetComponent();
Material newMat=new Material(UnityEngine.Shader.Find(“RenderFX/Skybox”));
Texture2D textRight=new Texture2D(1024,1024)
textRight.LoadImage(imRight);
newMat.SetTexture(“left”,textRight);
//same for the other images
//and then apply the material to the Skybox
sb.material=newMat;
Is it possible to do that with Unity pro 3.4.2?
If not is it possible to get the sources of these shaders of the editor?
I’m kind of new to those game IDEs. I was more used to low level 3D engines like Ogre and i would like to retrieve the same flexibility…