Using Noise generated Z-values to Assign Color

Hi all,

I’m working with the Simplex Noise node from the plugin Noise (by Liang M). I’m mostly interested in using this to create points/curves but I also wanted to incorporate color based on z-values.

I’ve shared my script below - this version uses boxes to display the color. I wanted discrete colors, so I’ve edited the gradient node to only show color blocks by changing the “left color” and “right color” options within the node.

If anyone has any neat shortcuts to the same solution, I would enjoy taking this further.

ZvalueColorGradient.gh (11.7 KB)

you can save one component here by using Face Normals instead of FaceBoundary + Area:

or you can just create points on the Surface directly, without going Mesh, which saves a few components:

the only other thing that comes to my mind is to use Z values directly from the generator, instead of retrieving those from the points you have just moved:

I’m saying this because the Bounds component reads the range from the lowest to the highest noise values, and that range would not change as long as you apply the Move to points which all have same starting Z value

if your target is to use as few components as possible, maybe you can also replace the Move component with an expression like this:

ZvalueColorGradient_Re.gh (13.5 KB)

Hello
If you want just n Colors from Gradient, you just need to input values limited. You can use Floor, Ceiling, Int … here a simple one with Int


94909b8c1037832cf28e94302e64ed4f999fe614.gh (15.8 KB)