LightmappedReflective: Difference between revisions
Jump to navigation
Jump to search
Bug:Adding proxies to a lightmappedreflective causes the texture to not be drawn. (Could this be because it includes some default proxy in order for it to work, and once there is a user-defined proxy, those "behind the scenes" proxies are no longer there?) [todo tested in ?]
Bug:Does not appear to work in Portal 2 [todo tested in ?]
mNo edit summary |
m (→Shader parameters: Added my thoughts on $maxreflectivity) |
||
Line 49: | Line 49: | ||
{{MatParam|$envmapmask|texture|Per-pixel opacity of reflection}} | {{MatParam|$envmapmask|texture|Per-pixel opacity of reflection}} | ||
{{MatParam|$minreflectivity|float|{{todo|What is this?}}}} | {{MatParam|$minreflectivity|float|{{todo|What is this?}}}} | ||
{{MatParam|$maxreflectivity|float|{{todo|What is this?}}}} | {{MatParam|$maxreflectivity|float|{{todo|What is this? It seems to do as the name suggests, controls the max reflection strength similar to $reflectance}}}} | ||
===Refraction=== | ===Refraction=== |
Revision as of 16:01, 24 December 2020
LightmappedReflective
is the shader used by func_reflective_glass. This shader renders real-time reflection and refractions similar to Water (shader).
Warning:All parameters listed in the example (except $bumpframe, %tooltexture and $surfaceprop) must be included when used, or func_reflective_glass may not work properly.
Example
The example shown here is materials/glass/reflectiveglass001.vmt
"lightmappedreflective" { "%tooltexture" "dev/flat_normal" "$refracttexture" "_rt_WaterRefraction" "$refractamount" "0" "$refracttint" "[.5 .5 .6]" "$reflecttexture" "_rt_WaterReflection" "$reflectamount" "0" "$reflecttint" "[1 1 1]" "$fresnelpower" "0" "$minreflectivity" "0.8" "$maxreflectivity" "1.0" "$normalmap" "dev/flat_normal" "$surfaceprop" "glass" "$bumpframe" "0" }


Todo: Does it work in portal 1?
Shader parameters
Textures
$basetexture
[[$normalmap|$normalmap]]
$bumpframe
$bumptransform
Reflection
$reflecttexture
$reflectamount
$reflecttint
$reflectance
$envmapmask
$minreflectivity
$maxreflectivity
Refraction
$refracttexture
$refractamount
$refracttint