Changer color of line after transparent shader?

Hi folks,

Really simple one this (i guess).

In the below image you can see that i have two images on a plane.

The top one is the original image.

The lower one has had all the white removed using a transparent shader.

My question is:

How do i change the color (black) of the remaining lines in the lower image to something else, like yellow for example, while keeping the transparency?

Here’s the BLEND file and image:
Durer.zip (1.0 MB)

Thanks!

Hi, you can use your existing color to mix between two other colors (mix node)

The ColorRamp node in your shader would be an easy place to start.

Thanks guys, any chance of a bit more explanation? (you’re mentioning different nodes, but not how to hook them up to achieve the desired effect - i tried but couldn’t get the right combination!)

Pipe your image into a mix color node, use the colors you please, then pipe the mix color node into a diffuse bsdf. Then pipe the image into the factor of a mix shader node, and plug the diffuse bsdf and the transparent bsdf into that mix shader node.

Thanks!

I’m getting the best result with this set-up.

If I mute the mix node, the result is worse, which i don’t really understand!

Your image should go into the factor of the mix node. Right now the factor is 1 which makes it output always blue

Wait, this works really good!:

1 Like