$envmap: Difference between revisions
Jump to navigation
Jump to search
m (This parameter is not limited to env_cubemap - other textures work as well.) |
(Updated entire list according to Koders Code Search.) |
||
Line 1: | Line 1: | ||
The $envmap [[VMT]] parameter defines the environment map of a material, normally reflecting the nearest [[env_cubemap]]. | The $envmap [[VMT]] parameter defines the environment map of a material, normally reflecting the nearest [[env_cubemap]]. | ||
== Basic VMT Syntax== | |||
"$envmap" | "$envmap" <texture> | ||
* This is the texture to use as the environment map. Normally | * This is the texture to use as the environment map (envmap). | ||
* Normally <nowiki><texture></nowiki> is set to ''"env_cubemap"''. | |||
== Additional Parameters == | |||
=== | === Adjust overall reflection color & contrast === | ||
====$envmapcontrast==== | |||
"$ | "$envmapcontrast" <float> | ||
* | * Controls the contrast (i.e. dynamic range) of the map. | ||
* | * The parameter accepts a value between ''0'' and ''1'', where ''0'' is the normal contrast, and ''1'' is the full squaring of the color (color*color). | ||
* Use higher contrasts to diminish relatively darker areas and increase "hot spots". | |||
=====$envmaptint | |||
====$envmapsaturation==== | |||
"$envmapsaturation" <float> | |||
* Controls the saturation of the map. | |||
* The parameter accepts a value between ''0'' and ''1'', where ''0'' is 100% greyscale, and ''1'' is normal saturation. | |||
====$envmaptint==== | |||
"$envmaptint" "[float float float]" | "$envmaptint" "[float float float]" | ||
* | * Controls the tint (red, green and blue components) of the map. | ||
* The default is ''"[1 1 1]"''. | |||
===Specular masking=== | |||
====$envmapmask==== | |||
"$envmapmask" | "$envmapmask" <texture> | ||
* Masks the | * Masks the map according to the alpha channel of the named <code><texture></code>. | ||
====$basealphaenvmapmask==== | |||
"$ | "$basealphaenvmapmask" <flag> | ||
* Masks the | * The default value is ''1''. | ||
* Masks the envmap according to the alpha channel of the [[$basetexture]] texture. | |||
====$normalmapalphaenvmapmask==== | |||
"$ | "$normalmapalphaenvmapmask" <flag> | ||
* | * The default value is ''1''. | ||
* Masks the envmap according to the alpha channel of the [[$bumpmap]] texture. | |||
====$envmapmasktransform==== | |||
"$ | "$envmapmasktransform" <matrix> | ||
* | * ? | ||
* The default is "center .5 .5 scale 1 1 rotate 0 translate 0 0". | |||
* DirectX 9 or HDR required. (LightmappedGeneric, VertexlitGeneric, UnlitGeneric) | |||
* Also see [[$envmapmaskscale]]. | |||
====$envmapmaskscale==== | |||
"$ | "$envmapmaskscale" <float> | ||
* | * Scales the [[$envmapmask]] by the <nowiki><float></nowiki> value. | ||
* DirectX 8 required. (LightmappedGeneric, VertexlitGeneric, UnlitGeneric) | |||
* Also see [[$envmapmasktransform]]. | |||
====$envmapmaskframe==== | |||
"$ | "$envmapmaskframe" <integer> | ||
* | * ? | ||
=== See Also | |||
=== Other parameters === | |||
====$envmapframe==== | |||
"$envmapframe" <integer> | |||
* ? | |||
====$envmapmode==== | |||
"$envmapmode" <flag> | |||
* Default is ''1''. | |||
====$envmapsphere==== | |||
"$envmapsphere" <flag> | |||
* Default is ''1''. | |||
====$basetexturenoenvmap==== | |||
"$basetexturenoenvmap" <boolean> | |||
* Default is ''0''. | |||
* DirectX 9 required. | |||
* See also [[$basetexture]]. | |||
====$basetexture2noenvmap==== | |||
"$basetexture2noenvmap" <boolean> | |||
* Default is ''0''. | |||
* DirectX 9 required. | |||
* See also [[$basetexture2]]. | |||
== See Also == | |||
* [[DirectX Versions]] | * [[DirectX Versions]] | ||
* Tutorial: [[Cubemap]]s in Level Design. | * Tutorial: [[Cubemap]]s in Level Design. | ||
* Tutorial: [[Reflective Materials]] | * Tutorial: [[Reflective Materials]] | ||
[[Category:List of Shader Parameters]] | [[Category:List of Shader Parameters]] | ||
[[Category:VMT Reflections]] | [[Category:VMT Reflections]] | ||
[[Category:Stubs]] | [[Category:Stubs]] |
Revision as of 14:30, 22 January 2008
The $envmap VMT parameter defines the environment map of a material, normally reflecting the nearest env_cubemap.
Basic VMT Syntax
"$envmap" <texture>
- This is the texture to use as the environment map (envmap).
- Normally <texture> is set to "env_cubemap".
Additional Parameters
Adjust overall reflection color & contrast
$envmapcontrast
"$envmapcontrast" <float>
- Controls the contrast (i.e. dynamic range) of the map.
- The parameter accepts a value between 0 and 1, where 0 is the normal contrast, and 1 is the full squaring of the color (color*color).
- Use higher contrasts to diminish relatively darker areas and increase "hot spots".
$envmapsaturation
"$envmapsaturation" <float>
- Controls the saturation of the map.
- The parameter accepts a value between 0 and 1, where 0 is 100% greyscale, and 1 is normal saturation.
$envmaptint
"$envmaptint" "[float float float]"
- Controls the tint (red, green and blue components) of the map.
- The default is "[1 1 1]".
Specular masking
$envmapmask
"$envmapmask" <texture>
- Masks the map according to the alpha channel of the named
<texture>
.
$basealphaenvmapmask
"$basealphaenvmapmask" <flag>
- The default value is 1.
- Masks the envmap according to the alpha channel of the $basetexture texture.
$normalmapalphaenvmapmask
"$normalmapalphaenvmapmask" <flag>
- The default value is 1.
- Masks the envmap according to the alpha channel of the $bumpmap texture.
$envmapmasktransform
"$envmapmasktransform" <matrix>
- ?
- The default is "center .5 .5 scale 1 1 rotate 0 translate 0 0".
- DirectX 9 or HDR required. (LightmappedGeneric, VertexlitGeneric, UnlitGeneric)
- Also see $envmapmaskscale.
$envmapmaskscale
"$envmapmaskscale" <float>
- Scales the $envmapmask by the <float> value.
- DirectX 8 required. (LightmappedGeneric, VertexlitGeneric, UnlitGeneric)
- Also see $envmapmasktransform.
$envmapmaskframe
"$envmapmaskframe" <integer>
- ?
Other parameters
$envmapframe
"$envmapframe" <integer>
- ?
$envmapmode
"$envmapmode" <flag>
- Default is 1.
$envmapsphere
"$envmapsphere" <flag>
- Default is 1.
$basetexturenoenvmap
"$basetexturenoenvmap" <boolean>
- Default is 0.
- DirectX 9 required.
- See also $basetexture.
$basetexture2noenvmap
"$basetexture2noenvmap" <boolean>
- Default is 0.
- DirectX 9 required.
- See also $basetexture2.
See Also
- DirectX Versions
- Tutorial: Cubemaps in Level Design.
- Tutorial: Reflective Materials