DirectionalMap
Overview
DirectionalMap blends colors based on alignment of the surface normal and a specified “prime direction.”
This is useful for view-dependent effects or physical phenomena like dust accumulating atop surfaces.
Note that DirectionalMap cannot know about downstream normal mapping; you must connect relevant normal maps to this node.
Attribute Reference
Adjustment attributes
bias
Float bindable
default: 0.5
controls the rate at which the effect increases as the shading normal approaches the prime direction
clamping_behavior
Int enum
0 = “clamp” (default)
1 = “absolute”
determines how surfaces facing opposite the prime direction are handled
falloff_type
Int enum
0 = “cosine” (default)
1 = “linear”
determines how the effect falls off as the difference angle increases
smoothstep_end
Float bindable
default: 0.55
the value at which the effect is considered 100% on
smoothstep_start
Float bindable
default: 0.45
the value at which the effect is considered 100% off
use_smoothstep
Bool
default: False
apply smoothstep function to result
Normal attributes
input_normal
NormalMap
default: None
specifies an alternate shading normal when bound. The binding multiplier is ignored
input_normal_dial
Float bindable
default: 1.0
controls the amount of influence of the alternate normal
General attributes
color_a
Rgb bindable
default: [ 0, 0, 0 ]
the color of the effect when the difference angle is greatest
color_b
Rgb bindable
default: [ 1, 1, 1 ]
the color of the effect when the difference angle is smallest
custom_direction
Vec3f bindable
default: [ 0, 1, 0 ]
specifies a custom direction in world space as the prime direction
object
Node
default: None
the object to use when 'prime direction' is set to 'axis of object' or 'look-at object'
object_axis
Int enum
0 = “+X axis”
1 = “-X axis” (default)
2 = “+Y axis”
3 = “-Y axis”
4 = “+Z axis”
5 = “-Z axis”
which axis to use when 'prime direction' is set to 'axis of object'
polarity
Int enum
0 = “perpendicular” (default)
1 = “parallel”
determines which directions are given color A and which are given color B. Switching this effectively swaps the colors
prime_direction
Int enum
0 = “observer direction” (default)
1 = “custom direction”
2 = “axis of object”
3 = “look-at object”
which source is used for the prime direction
use_reference_space
Bool
default: False
use reference space position and normals