Using alpha texture to control colour in cracks

I am trying to achieve a specific effect using nodes and a black and white cavity map.

at the moment i have ambient occlusion and a cavity map working quite well to give the cracks and crags of my model some much-needed dirt and depth.

However, I would also like to use a copy of my cavity map to make some of the cracks glow like red hot rocks. i want to use some sort of node mix set up which will allow me to use the cavity map copy to define what cracks are red and glowing and what cracks stay dark and muddy.

unfortunately, my understanding of nodes is lacking and i am struggling to find the right set up that will let me use the cavity alpha copy to define glowing areas.

i can make the material look dark and shady but how can i use the alpha to define the colour in specific parts of the texture. i have tried to link it to the fac and various mix shaders but all i get is an overall mix of the 2 colours instead of controlling the colours in the cracks alone using the alpha.

can anyone give me some pointers?

thank you.



If dark is creating cracks and you want glow, consider inverting the alpha (with color ramp for control), which then controls emission color and strength. You can add it to the main material, mix it with the main material, or both, depending on what you think looks best. I’m using add then mix here:

I’m using color output as I grabbed a snapshot of your image though, over some whatever other material.

If you are having a hard time understanding how the nodes work, then this post where I explain how to recreate photoshop layers with nodes might help you out:

I would do what carl said and invert the black and white texture, then use that as the factor in a mix shader that mixes the main shader for the body with an emission shader. If you don’t want the glow to be uniform across the whole crack, then I’d multiply the inverted cracks texture with a noise texture and use that as the factor for the mix shader.