1 Your mission
make the robot’s shadow match the plate: the umbra within 6% of Blender’s in every channel, and contact AO that brings the feet closer to Blender’s render.
The shadow starts black (level 0) with no AO. Sample a shadow on the same sand that lies under the robot; a shadow hugging a rock sees less sky and is darker than open sand in shadow. Compare channel by channel, not just overall brightness, and keep the AO near the feet.
2 Why it works
A shadow is the plate with the sun blocked: what’s left is the light from the sky, so a real shadow has a colour (bluish here), never black. The shadow on this plate’s sand is 0.39 / 0.44 / 0.52 (R / G / B) of the lit sand. Its density and colour can be measured from the shadows already in the plate.
Click inside a rock’s shadow, then on the lit sand beside it, and read the plate “shadow ÷ lit” per channel. Set the “level in the shadow” and the “shadow colour” until your shadow matches the plate, then add contact AO. Watch the feet zoom and the “umbra vs Blender” and “at the feet (contact)” readouts.
plate × (1 − m · (1 − shadow colour)) × AOWhere the numbers come from: Every picture is a Blender 5.2 Cycles render of our own desert and robot, computed in your browser. The shadow passes are Blender shadow-catcher renders: sun only (the shadow matte), and the ground’s AO pass with and without the robot (contact AO). The reference is the shadow catcher with both the plate’s sun and sky. The goal is the umbra ratio against Blender plus AO that helps the feet; the whole-shadow error is shown but is not the goal, because render noise dominates it. The shadow formula here is a teaching version of the usual Grade/Multiply setup.