This article's documentation is for anything that uses the Source engine. Click here for more information.

PaintBlob

From Valve Developer Community
Jump to navigation Jump to search
An ice surface using the PaintBlob shader
This article or section is a stub. You can help by expanding it.

PaintBlob is a Pixel shader available in all Source Source games since Portal 2 Portal 2. Originally intended for Gel blobs, it can also be used to create realistic hollow ice surfaces.

Note.pngNote: $nocull is not needed for this shader to function properly, however, can be used to visualize the $interior effects on the backface.
Todo: Report anomalies and bugs
Icon-Bug.pngBug:Non-functional in Source Filmmaker  [todo tested in ?]

Supported Parameters

Textures & Masks

$basetexture <texture>
Diffuse texture.
$normalmap <texture>
Normal map.
$envmap <string>
Specular reflection.
$lightwarptexture <texture>
1D ramp texture for tinting scalar diffuse term.
$backsurface <boolean>
Specify that this is the back surface.
Icon-Bug.pngBug:Results in a pixel shader crash if true.  [todo tested in ?]
$specmasktexture <texture>
Mask texture for specular reflection.
$fresnelwarptexture <texture>
1D ramp texture for controlling fresnel falloff

{{MatParamDef|$opacitytexture|texture|text=Typically, a grayscale texture that defines the opaque and translucent parts of the texture.

Outer Layer Parameters

$diffusescale <float>
Scales the output color.
Tip.pngTip: Can be used to brighten the textures.
$phongexponent and $phonexponent2 <float>
Specular exponent values.
$phongboost and $phongboost2 <float>
Specular boost values.
$rimlightexponent <float>
Rim light exponent.
$rimlightboost <float>
Rim light boost.
$basecolortint <vector3>
Base texture tint.
Todo: Figure out why this doesn't work.

Interior Volume Parameters

$interior <boolean>
Enable interior layer.
$interiorfogstrength <float>
Fog strength (scales with thickness of the interior volume).
$interiorbackgroundboost <float>
Boosts the brightness of bright background pixels.
$interiorambientscale <float>
Scales the ambient light in the interior volume.
$interiorbacklightscale <float>
Scales backlighting in the interior volume.
$interiorrefractstrength <float>
Strength of bumped refract of the background seen through the interior.

Additional Parameters

$uvscale <float>
UV projection scale. Default: 0.02.
$bumpstrength <float>
Bump map strength.
$fresnelbumpstrength <float>
Bump map strength for the fresnel term.
$translucentfresnelminmaxexp <vector3>
Fresnel range parameters for the opacity texture.
$uvprojoffset <vector3>
Center for UV projection.
$bbmin and $bbmax <vector3>
Todo: Functional?
$contactshadows <boolean>
Darkens the shading of the material in areas where it is in contact with a surface.
$bumpframe <integer>
Bump frame.
$alphatest <boolean>
Tip.pngTip: Has no effect on the alpha, but effects shadow casting
$translucent <boolean>
Tip.pngTip: Has no effect on the alpha, but effects shadow casting
$surfaceprop <string>
$nocull <boolean>