Free Blender 2.8 - HeightBlendV1
Blending various materials based on height/displacement maps is something I always wanted to have in Blender. That is why I created two material node groups to do this, just like Substance Designer or Quixel Mixer!
Check the HeighBlendV1.blend file for notes and descriptions.
Here is a tutorial explaining the workflow: https://www.youtube.com/watch?v=8p7g6tiaDwU&feature=youtu.be
HeightBlend:
Inputs:
Weight: Determines which material/layer is used, generally, white adds material A over a black material B.
Height-A/B: Input the height/displacement map.
Scale-A Adjustment: Expands material/layer A.
Midlevel-A/B: Value to determine the displacement direction, in this case how it will blend.
Scale-A/B: Determines the displacement amount, large differences in the scale values (example A=1, b=12) creates sharper or softer blending between materials.
Height Mask Invert: Invert the height.
Height Mask Contrast: Extra sharpening or softening.
Height Mask Brightness: Extra coverage. Changing both the contrast and brightness parameters. might create alternate results.
Displacement Midlevel: Object midlevel, like the displacement modifier.
Displacement Scale: Amount of displacement, like the displacement modifier.
Displacement Balance: Brings back the underlying layer.
Swap Materials: Changing this parameter swaps the layering effects, but preserves the HeightBlend parameters.
Wireframe Size: Use this in combination with the Wireframe Preview to visualize the current density and surface displacement.
Mat-A/B: Input of the materials.
Displacement Mix: Input the previous HeightBlend Displacement Output for accurate mixing
Outputs:
Height Mask Output: Mask for artistic mixing or to mask custom materials/parameters.
Height Mix Output: You can use this output to chain multiple HeightBlend materials for accurate mixing.
Material Output: Output for the Surface Material Input.
Displacement Output: Output for the Displacement Material Input.
WireFrame Preview: Output to visualize the current density and surface displacement.
HeightBlendWater:
Inputs:
Water Input: Determines which material/layer is used, generally, white adds material A over a black material B.
Height Mix Input: Insert the Height Mix Output or another Height map.
Reflection: How much the water reflects
Water Roughness: Change the roughness, perhaps useful for ice.
Base Color: Color of the water.
Water Height: Amount of water.
Muddy - Clean: The amount of absorption.
Puddle Displacement: Extra geometrical displacement to deepen the puddle.
Material Input: Use the HeightBlendMaterial Material output or a custom output.
Displacement Mix: Use the HeightBlendMaterial Displacement Output or a custom output
Water Normal: Add a normal/bump maps to add ripples or other normal effects. (might need to change the material settings to use both displacement or Bump)
Outputs:
Weight Mix Output: the final output of the water mask.
Water Material Output: Output for the Surface Material Input.
Displacement Output: Output for the Displacement Material Input.
HeightBlendV1