$selfillum: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
Line 1: Line 1:
{{otherlang2
#redirect [[Glowing Textures#$selfillum textures]]
|fr=$selfillum:fr
}}
The [[$selfillum]] [[VMT command]] makes a material glow in the dark. Shaders commonly support this effect.
 
The effect is masked by default by the [[alpha channel]] of <code>[[$basetexture]]</code>, but there are other options (see below). Wherever the mask is located, white areas are self-illuminated while black areas are not.
 
{{Warning|Cannot be used with <code>$translucent</code> or similar values on [[model]]s. Use [[UnlitGeneric]] shader instead}}
 
 
==VMT syntax example==
 
$selfillum <[[bool]]>
 
[[LightmappedGeneric]]
{
    [[$basetexture]] props/tvscreen005a
    '''$selfillum 1'''
    [[$surfaceprop]] glass
}
 
==Additional parameters==
 
; <code>$selfillumtint "[<red [[float]]> <green float> <blue float>]"</code>
: Adjusts the colour of the self-illumination effect. Default value is "[1 1 1]".
 
 
;<code>$selfillummask <texture></code> {{note|In Source 2007, use this, NOT $Selfillumtexture.}}
 
 
: A dedicated mask texture for the effect. Might not work in Ep1.
; <code>$selfillum_envmapmask_alpha <[[bool]]></code>
: Has the material derive its self-illumination mask from the alpha channel of the <code>[[$envmapmask]]</code>. Requires DirectX 9.
 
 
;<code>$selfillumtexture <texture></code>
: Use a selfillum texture.
{{Bug|Deprecated with Source 2007; doesn't work.}}
 
;<code>$selfIllumFresnel<[[bool]]></code>
:Allows the material to use Fresnel ranges. {{Todo|Confirm}}
 
;<code>$selfIllumFresnelMinMaxExp [n n n]</code>
:Default: 0.0 1.0 1.0.  Like the phong Fresnel ranges, but with selfillum.
 
[[Category:List of Shader Parameters|S]]
[[Category:VMT Lighting]]
[[Category:English]]

Revision as of 06:25, 8 April 2015