Docs

Guides

Your own material

Add Ground Blend to your own master material with one MF_GB_Apply node, plus every input, output and helper function.

Use this when your project has its own master material (layered rock, moss, wetness and so on). Materials/Examples/M_GB_Example_CustomMaster is a finished example.

  1. In your material's Details, tick Use Material Attributes, and build your outputs with a Make Material Attributes node (base colour, normal, roughness, ambient occlusion and anything else you use).
  2. Add MF_GB_Apply (Content/GroundBlend/Core) and connect Make Material Attributes to its Rock input.
  3. Add three Texture Object nodes with the ground set (for example T_GB_ForestSoil_BC, _N, _R) to GroundBaseColor, GroundNormal and GroundRoughness, and set GroundTile_cm (a constant or a scalar parameter).
  4. Connect MF_GB_Apply Result to the material output. Expose BlendHeight, BlendNoise and the switches you want as parameters. Instances, Nanite and instanced meshes then work as with the master.
Diagram of M_GB_Example_CustomMaster

The material must be opaque (Surface domain). The functions are pixel-shader only: do not drive World Position Offset with them.

MF_GB_Apply inputs#

Every input except Rock is optional and has the default shown.

Input Default Meaning
Rock Your material's attributes (Make Material Attributes).
GroundBaseColor / GroundNormal / GroundRoughness grey / flat / roughness 1 The ground set (normal DirectX, roughness in red).
GroundTile_cm 200 World size of one ground tile in cm.
BlendHeight / BlendNoise 30 / 10 Band height and edge noise in cm.
RockHeight 0.5 Rock relief 0 (crevice) to 1 (peak): crevices fill first; 0.5 = even band. The master derives it from the rock colour and AO (Crevice Gain).
Amount 1 0 = off, 1 = full.
TerrainColourStrength 1 How much the captured terrain colour tints the ground set.
SlopeBias / DustUp 0.3 / 0.25 As in the master (The master material).
Contrast / SoftFalloff / NoiseSize_cm 0.35 / 0 / 60 As in the master.
ContactDarkening / SeamNormalMatch 0.25 / 0.8 As in the master. The master's own Contact Darkening default is 0.1; set 0.1 here to match it.
FillSteep / DustStrength / DustReach 0 / 0.85 / 1.75 Fill On Steep Faces, Dust Strength and Dust Reach, as in the master.
GroundTint / GroundSaturation (1, 1, 1) / 1 Ground colour multiplier and saturation.
GroundNormalStrength / GroundRoughnessScale 1 / 1 Ground normal strength and roughness multiplier.
FallbackGroundZ 0 Ground Z in cm when UseCapture is off.
UseCapture / UseCapturedColour / ColourOnly on / on / off Static switches, as in the master.
FarFade_cm (4000, 9000) The ground normal fades out between these camera distances.
SurfaceNormal vertex normal World normal used for the top-down choice on near-horizontal faces, the steep-face fill, Slope Bias and Dust Up.
Output Meaning
Result Blended material attributes: connect to the material output.
Alpha Ground weight 0 to 1 (drive extra layers such as wetness with it).
HeightAboveGround cm above the captured terrain.

The other functions and the parameter collection#

Asset What it is
MF_GB_HeightAboveGround No inputs. Outputs HeightAboveGround (cm; 100000 where there is no ground), GroundZ, TerrainNormalWS, Weight (capture active x inside the area x GB_Amount), ColourWeight, CaptureUV.
MF_GB_GroundSample The ground set sampled in world space: top-down where the face is near horizontal, otherwise one of two world side planes chosen by the face of the mesh's own bounding box the pixel lies on (ProjectionSharpness 6 sets how narrow the X / Y blend is), optionally tinted by the captured colour (the capture sets the hue and brightness, the set its grain). Outputs Ground (attributes), BaseColor, Roughness, NormalTS, NormalWS, FlatNormalWS, UV, ProjectionWeights, DustColour, DustRoughness (the set's average for the dust film).
MF_GB_Blend Mixes the ground into the rock in two layers, the fill and the dust film (all band controls above, plus DistanceWiden 0.004: the band stays 2 to 3 pixels wide far away, and ContactHeight_cm 6). Outputs Result, Alpha (fill weight), Seam, Contact, Dust.
MPC_GroundBlend GB_Frame, GB_Info, GB_Global (Global Enable x Global Strength) and GB_BandScale (Global Band Scale), all written by the capture actor, plus GB_Amount (default 1, never written by the actor): a global multiplier on every blend for your own scripts, a graphics-settings menu or Sequencer, with Set Scalar Parameter Value. It fades the look; to save shader cost use UseGroundBlend or ColourOnly.