Geometry nodes, how to control a gradient texture node

I’m trying to scale the size of instances with a gradient texture.
But I can’t figure out how to control the texture, and I don’t know why the gradient texture seems to start in the middle of the mesh?

Any tips on how I can control the texture?
I actually want to make the transition from top to bottom and to cover the whole object.

Hi there!

I dont have my rig on, so cant show, but the linear gradient texture starts at the middle on the X axis, when picking no coordinate system. Generated obj coordinates for examole will start from the left side. So you can try to insert a Texture coordinate node set to generated, you can check it against UV or object, you will see the difference, so you just run generated into the vector of your gradient texture.

You could also go with another coordinate input that leaves it at the middle, and slide that zero point to the beginning on the left. With a vector math node for example. Add I guess, then tweak that one axis.

Another solution is a Geometry node, out of p
Position, into a separate XYZ, you pick the right one you need, then run that into a math node to slide said texture, then use a color ramp or map range to tweak further

You can check that kinda solution here. Different setting, same logic, from 2:00

Later I can show you myself if still unsolved :blush:
Cheers!

1 Like

Wow, super interesting tutorial.

I tried the Position, into a separate XYZ, and it was working but didn’t look as cool as I would have liked.
Found this tutorial that can maybe make is look cooler.

1 Like

could this work with the selection input of the node? Have points with a gradient distribution on the surface?

Welcome necro-poster!

Pro-tip to avoid necro-posting:
Start a new topic and reference dormant posts from there…

To answer your question:

No. The selection input is a Boolean. i.e. when converting from a float it will be true for any value greater than 0 - i.e. with Booleans it’s all-or-nothing. If you would like a solution which does do a gradient of distribution density, feel free to start a new topic.

Good luck!

1 Like