Sky (shader)

From Valve Developer Community
Jump to: navigation, search

Sky is a shader for materials in Source meant for 2D skyboxes. The old method of making skyboxes before Source 2007 involved using the UnlitGeneric shader with $ignorez 1. This shader expands the amount of usable parameters and also allows for HDR skyboxes.

Most of the time, VMTs should only exist for HDR skyboxes that have an LDR fallback. An example of an HDR skybox with a fallback will look like this:

	"$hdrcompressedTexture" "skybox/sky_wasteland_00_hdrup"	
	"$nofog" "1"
	"$ignorez" "1"
	"$basetexture" "skybox/sky_wasteland_00up"          // VMT will load this VTF instead if not running in HDR.
	"$basetexturetransform" "center 0 0 scale 1 2 rotate 0 translate 0 0"          // For cutting off the bottom halves of the skybox