Shadow
The Shadow section turns lighting into toon shading: surfaces facing away from the light switch to a shadow color with a controllable edge, instead of fading smoothly to black. NekoToon supports up to three stacked shadow colors, masks that control where and how the shadow appears (including face SDF shading), an AO map, and options for cast shadows and ambient light.
Find it under Color > Shadow. The section is not shown in Gem mode. Related settings that also shape the shadow live elsewhere: anti-aliasing of the shadow edge (Anti-aliasing shading) and Backface Force Shadow are in Base Setting, the light direction and light limits in Lighting; darkening at the edge of the silhouette is Rim Shade.
How the shadow is built#
For every pixel the shader takes the angle between the surface and the main light and turns it into a value from 0 (facing directly away) to 1 (facing the light), with 0.5 at a right angle. Each shadow layer compares that value with its Border: below it the pixel is in that shadow, above it the pixel is lit, and Blur sets how wide the transition is. The 1st shadow decides what is lit and what is shaded. The 2nd and 3rd shadows are painted on top inside the shaded area, usually with lower borders to create darker cores.
Shadow colors multiply the base color (from Main Color and the layers), so a light lavender shadow color gives a slightly darker, slightly cooler version of whatever is underneath. The shaded result is never brighter than the lit result.
Shadow#
Shadow#
_UseShadow toggle · default off
Turns toon shading on. When it is off, the material is simply multiplied by the light color with no shading terminator, which gives a flat, evenly lit look.
Mask Type and Strength#
Mask Type#
_ShadowMaskType Strength | Flat | SDF · default Strength
Decides what the mask texture below means.
- Strength: the mask's red channel scales the shadow strength, so black areas never get shadow.
- Flat: the mask blends between normal shading and a flat shading that ignores the surface shape and only looks at where the light is relative to the object's front. Used for faces that should be lit as one even plane.
- SDF: uses a signed-distance-field face shadow texture, which gives clean, hand-designed shadow shapes on a face as the light moves around.
Mask & Strength#
_ShadowStrengthMask texture, red channel · default white _ShadowStrength 0 – 1 · default 1
Shown for Mask Type Strength. The slider sets how strong the whole shadow is (1st, 2nd and 3rd together): 0 removes it, 1 uses the full shadow colors. The texture multiplies the strength per pixel, so you can paint out shadow on areas such as the eyes or a glowing part.
Mask (Flat)#
_ShadowStrengthMask texture, red channel · default white
Shown for Mask Type Flat. White uses normal shading, black uses flat shading. The default white texture therefore changes nothing; paint black where flat shading is wanted (typically the face). Strength is then only set by the Strength slider, not by the mask.
Border (Flat)#
_ShadowFlatBorder -2 – 2 · default 1
Shifts the flat shading toward lit (higher) or shaded (lower). The flat value is based on the angle between the light and the object's forward direction (tilted slightly upward), so with the default the object is lit as long as the light is roughly in front of it.
Blur (Flat)#
_ShadowFlatBlur 0.001 – 2 · default 1
How gradually the flat shading changes as the light moves around the object. Small values switch between lit and shaded almost instantly.
SDF#
_ShadowStrengthMask texture RGBA · default white
Shown for Mask Type SDF. The channels are used as follows: R is the SDF used when the light comes from the right, G when it comes from the left, B blends between the SDF shading (0) and normal shading (1), and A works as the strength mask. Because the default white texture has B = 1, the face area of your texture needs B = 0 for the SDF to take effect. The SDF result still goes through the 1st/2nd/3rd Border and Blur, and the shading anti-aliasing is turned off for it.
Left, right and front come from the mesh object's own axes: +Z is treated as forward and −X as the character's right side. If the shadow moves the wrong way, check how the mesh is oriented.
Blend Y Direction#
_ShadowFlatBlur 0.001 – 2 · default 1 · SDF only
How much the light's height counts in SDF mode. At 1 the full 3D angle is used; lower values flatten the vertical part of both the light and the face direction, so the shadow mostly follows the light's horizontal angle (useful when lights from above should not wash out the face shadow). It is the same property as Flat Blur.
LOD#
_ShadowStrengthMaskLOD 0 – 1 · default 0
Blurs the mask texture by sampling a lower-detail mip level. Raise it a little to soften a low-resolution or hard-edged mask. 0 samples it normally.
Strength#
_ShadowStrength 0 – 1 · default 1
For Flat and SDF this slider appears on its own line; it is the same overall shadow strength described under Mask & Strength.
Shadow Colors#
Color Type#
_ShadowColorType Normal | LUT · default Normal
How the shadow color textures are read. Normal: they are ordinary textures in the main UV layout (RGB = shadow color, A = how much the texture replaces the base color). LUT: they are color lookup tables (a 256×16 strip of 16 slices); the shader looks up the base color in the table and uses the result as the shadow color, so each base color gets its own hand-picked shadow color regardless of UV.
1st Color#
_ShadowColorTex texture · default black (no effect) _ShadowColor color · default (0.82, 0.76, 0.85)
Color of the main shadow. Without a texture, the shadow is the base color multiplied by this color. With a texture, its RGB replaces the base color where its alpha is 1 (painted shadow colors), and the result is still multiplied by the color. White means "no darkening" and makes the shadow invisible; lighter, slightly saturated tones look more anime-like than gray.
Border#
_ShadowBorder 0 – 1 · default 0.5
Where the 1st shadow starts. 0.5 puts the terminator where the surface is at a right angle to the light. Higher values make more of the model shaded, lower values less.
Blur#
_ShadowBlur 0 – 1 · default 0.1
Softness of the 1st shadow edge. 0 is a hard cel-shaded line, around 0.1 a slightly soft toon edge, and high values approach smooth realistic shading. The edge is centered on Border.
Normal Map Strength#
_ShadowNormalStrength 0 – 1 · default 1
How much the normal map affects the 1st shadow. Lower it to keep shadow shapes clean and follow the mesh instead of the fine normal-map detail. Has no effect without a normal map.
Receive Shadow#
_ShadowReceive 0 – 1 · default 0
How much real-time shadows cast by objects (including the avatar itself, e.g. hair onto the face) darken into the 1st shadow. 0 ignores cast shadows entirely, so shading depends only on the surface angle. Only has an effect where the world has a real-time light that casts shadows.
2nd Color#
_Shadow2ndColorTex texture · default black _Shadow2ndColor color · default (0.68, 0.66, 0.79, 1)
A second shadow drawn inside the shaded area, usually darker, for a two-tone shadow. Texture and color work like the 1st Color.
Alpha#
_Shadow2ndColor.a 0 – 1 · default 1
Strength of the 2nd shadow. At 0 it is off and its Border, Blur, Normal Map Strength and Receive Shadow are hidden.
Border / Blur / Normal Map Strength / Receive Shadow (2nd)#
_Shadow2ndBorder 0 – 1 · default 0.15 _Shadow2ndBlur default 0.1 _Shadow2ndNormalStrength default 1 _Shadow2ndReceive default 0
Same meaning as for the 1st shadow, but for the 2nd layer. Keep the 2nd Border below the 1st Border so the darker tone sits deeper in the shadow; the default 0.15 only reaches the side facing almost directly away from the light.
3rd Color#
_Shadow3rdColorTex texture · default black _Shadow3rdColor color · default (0, 0, 0, 0)
A third shadow layer, applied after the 2nd. It is off by default (alpha 0). Use it for an extra tone, for example a colored band or a very dark core.
Alpha#
_Shadow3rdColor.a 0 – 1 · default 0
Strength of the 3rd shadow. Raise it above 0 to enable the layer and show its settings.
Border / Blur / Normal Map Strength / Receive Shadow (3rd)#
_Shadow3rdBorder 0 – 1 · default 0.25 _Shadow3rdBlur default 0.1 _Shadow3rdNormalStrength default 1 _Shadow3rdReceive default 0
Same meaning as for the 1st shadow, for the 3rd layer.
Border Color#
Border Color#
_ShadowBorderColor color · default (1, 0.1, 0)
Tints the transition between light and the 1st shadow. Inside the edge band, each color channel is pulled back toward the lit color by the amount in this color, so the default (mostly red) gives a warm, reddish edge, like light scattering under skin. Set it to black to turn the effect off.
Border Range#
_ShadowBorderRange 0 – 1 · default 0.08
How far the Border Color band extends from the edge into the shadow. 0 limits it to the Blur area; higher values give a wider glow of color on the shadow side.
Shadow Adjustments#
Contrast#
_ShadowMainStrength 0 – 1 · default 0
Multiplies the shadow color by the base color once more. This makes shadows darker and more saturated in the hue of the texture (red cloth gets a deeper red shadow), which looks richer than a plain gray darkening.
Environment strength on shadow color#
_ShadowEnvStrength 0 – 1 · default 0
Lets ambient light (light probes and environment lighting) brighten the shadow back toward the unshaded base color. At 0 the shadow color is fixed; at 1, in a world with strong ambient light, shadows become faint. Raise it if your avatar looks too contrasty in evenly lit worlds.
Shadow Caster Bias#
_lilShadowCasterBias float · default 0
Moves the shadow this material casts away from the light by this distance. A small positive value reduces self-shadowing artifacts (stripes or blotches on the avatar) when Receive Shadow is used. Too high a value detaches cast shadows from the objects. In the Built-in pipeline it is ignored for spot-light shadows. The same property also appears in the Rendering section.
Blur Mask#
Blur Mask#
_ShadowBlurMask texture RGB · default white
Varies the Blur per pixel: R multiplies the 1st shadow's Blur, G the 2nd's and B the 3rd's. Black gives a hard edge, white the full Blur value. Use it for soft shadows on skin and crisp ones on clothes within one material.
AO Map#
A foldout with a texture slot. The AO (ambient occlusion) map makes shadow appear more easily in creases and covered areas, such as under the chin, inside sleeves or between fingers.
AO Map#
_ShadowBorderMask texture RGB · default white
R affects the 1st shadow, G the 2nd and B the 3rd. The map is multiplied into the lighting value before the Border test, so darker areas fall into shadow sooner and black areas are always shaded. A grayscale AO bake in all three channels is the usual input.
Ignore border properties#
_ShadowPostAO toggle · default off
Applies the AO map after the Border / Blur step instead of before. The AO then darkens the shading directly in proportion to its value, giving soft AO shading that does not depend on Border and Blur. Leave it off for toon-style AO that snaps to the shadow edge.
1st / 2nd / 3rd Min and Max#
_ShadowAOShift 1st, 2nd (scale, offset) _ShadowAOShift2 3rd (scale, offset) · sliders -0.01 – 1.01 · default Min 0, Max 1
Remaps the AO map per channel: the texture value at Min becomes 0 and the value at Max becomes 1, with everything clamped. Narrow the range to increase AO contrast, raise Min to ignore light occlusion, or swap Min and Max to invert a channel. The inspector stores them as scale and offset.
NekoToon Lite#
In NekoToon Lite the Shadow box is reduced to: 1st Color texture with Border and Blur, 2nd Color texture with Border and Blur, Environment strength on shadow color, Border Color and Border Range. In Lite the shadow colors come from the textures only (texture RGB = color, alpha = amount), and there are no masks, no 3rd shadow and no Receive Shadow.
Tips for avatars#
A common starting point is the default setup: 1st shadow at Border 0.5, Blur 0.1 with a light, slightly purple or warm color, and the 2nd shadow at a low Border for a darker core. For a softer look raise the 1st Blur to 0.3–0.5; for a crisp cel look set it near 0.
For faces, harsh shadows across the nose and cheeks are the usual complaint. Options, from simplest: lower Strength on the face with a mask; use Mask Type Flat with a black face mask; or use an SDF face shadow texture. Lowering Normal Map Strength also keeps facial shadows clean.
Very dark or gray shadow colors make avatars look dirty or almost black in dim worlds, because the shadow is multiplied by the world light as well. Prefer lighter, tinted shadow colors and adjust depth with the 2nd shadow or Contrast. Also keep the 1st Color off pure white unless you want no visible shadow.