DocsReference

Flat colours on a rough surface

Face sampling gives each face one colour. On a displaced surface it starts painting wedges instead of faces, and it gets worse the rougher the surface is, because the four corners of a cell move independently and the cell stops being flat.

Set Faces in Quad mode before the ramp recovers a good part of it, but not all of it, and it cannot. The real fix is resolution: more divisions means less bend across any one cell. On a plane displaced hard, going from 12 divisions to 48 took the faces reading correctly from two thirds to nearly all of them.

If you need the colour to be exact rather than close, set the ramp's Output to Texture. That bakes the ramp to a gradient strip with real coordinates, so colour is decided per pixel rather than per corner, and a face sits on one texel.

Open the editor and try it