Hi,
I’d like to use a background technique that might be a bit unusual: Similar to a skybox, I have a skysphere, i.e. a sphere with inverted normals and a texture made for it.
My guess is that I’d have to reparent that model to the camera, set some layer for it and then I’d have to make that layer render first, then everything else above that. How is that possible in Unity? Or something else?
Actually sky spheres aren’t that uncommon. I’ve seen them before in game projects. In my eyes, they actually do make more sense than sky boxes.
The answer is quite simple. To render the sky sphere first, you’ll have to create an additional camera (which would have the same position and settings as the other camera), and which only renders the sky sphere. Your original camera will then render everything, except the sky sphere.
Now all you have to do is to set the clear flags to Depth only on the original camera, and make sure it is rendered last by setting the Depth value in both cameras. This will ensure that other object will always be on top of the sky sphere, even if they’re actually positioned behind it.
[edit]
Note that the same technique could also be used to render some UI behind your 3D models when using a system similar to UIToolkit (didn’t try it though, but it should work).
[/edit]