Legacy Documentation: Version 4.5
Previous
Occlusion Portals
Next
LOD Group

Skybox

Switch to Scripting

Skyboxes are a wrapper around your entire scene that display the vast beyond of your world.

Properties

Property: Function:
Material The Material used to render the Skybox, which contains 6 Textures. This Material should use the Skybox Shader, and each of the textures should be assigned to the proper global direction.

Details

Skyboxes are rendered before anything else in the scene in order to give the impression of complex scenery at the horizon. They are a box of 6 textures, one for each primary direction (+/-X, +/-Y, +/-Z).

You have two options for implementing Skyboxes. You can add them to an individual Camera (usually the main Camera) or you can set up a default Skybox in Render Settings’s Skybox Material property. The Render Settings is most useful if you want all Cameras in your scene to share the same Skybox.

Adding the Skybox Component to a Camera is useful if you want to override the default Skybox set up in the Render Settings. E.g. You might have a split screen game using two Cameras, and want the Second camera to use a different Skybox. To add a Skybox Component to a Camera, click to highlight the Camera and go to Component->Rendering->Skybox.

Unity’s Standard Assets contain 2 pre-setup Skybox materials in Standard Assets->Skyboxes.

If you want to create a new Skybox, use this guide.

One of the default Skyboxes found under <span class="doc-menu">Standard Assets->Skyboxes</span>
One of the default Skyboxes found under Standard Assets->Skyboxes

Hints

  • If you have a Skybox assigned to a Camera, make sure to set the Camera’s Clear mode to Skybox.
  • It’s a good idea to match your Fog color to the skybox’s color. Fog color can be set in Render Settings.
Previous
Occlusion Portals
Next
LOD Group