How to change the color of color ramp using drivers?

im trying to create a custom toon shader to publish for the community
but i cant seem to change the color ramp color with drivers? im using a group for this shader, so i need drivers to be able to drive its rgb valus with a simple color node image
image


i targeted the right shadow color directory i have no idea why it gives me an error

I think you could do this with this node setup by DanielFox :


It gives you inputs for the colour slots of the ramp
(note I have also used it to input images and mix them with colour ramps)

You need to make a driver for each RGB or HSV value.

How do you put drivers into HSV? The right click menu of HSV gives no options. You can not keyframe HSV either. I think that is the case because RGB are actual channels while HSV is only a representation of RGB mixed together.

There is a workaround via a separate/combine HSV node, though.

I didn’t know we can’t add driver to HSV. I thought it was the same as RGB. Then we need to use combine HSV if we want a HSV driver.

well it doesnt let you use drivers for color ramps rgb so probably the same with hsv

It does? I’m copying the color from the RGB node to the ColorRamp using drivers.

You can also add drivers to the combine RGB node to keep the values visible.

1 Like

but now can you control that rgb node outside the group?

please show me how did you set up these drivers and does it work outside the group

It work outside of the group and between different materials.

To set up these drivers, right click the a color channel from the RGB node (or any node that has a color picker), select “Copy as New Driver”. Then in the color picker of the ColorRamp, right click the same channel and select “Paste Driver”. Do the same for other channels.

ramp driver.blend (776.3 KB)

2 Likes

Edit Sorry my post was irrelevant, you already did that.

this seems promising ill have to check it out