Believable3D opened this issue on Dec 30, 2009 · 44 posts
bagginsbill posted Mon, 15 February 2010 at 5:10 PM
Quote - First, you want the areas of the "mask" that you want to not glow be black, and then connect it through a Math Functions node to the Ambient Color.
In the attached picture, the black areas in the second image map will render whatever the Color Texture and Diffuse Color are, while only the white areas will render with the Ambient Color.
No need for the math node.
If you plug the black-and-white image into a color (Ambient_Color here), it amounts to the same thing.
If you plug the the black-and-white image into a number, the three values are averaged to produce a single number. But since the image is black and white, the average of r, g, and b is the same as any of the individual values - it already is gray scale.
So you have GREEN * 1 * Mask. This is the same as GREEN * Mask.
And the math behind the Ambient_Color and Ambient_Value is multiplication.
So the full math is Ambient_Value * Ambient_Color * 1 * Mask = 1 * GREEN * 1 * Mask = GREEN * Mask. Same thing.
You could also plug the mask into Ambient_Value instead, and nothing would change. The math then is Ambient_Value * Mask * Ambient_Color = 1 * Mask * GREEN = Mask * GREEN.
No matter how you do it, in the end you have Mask * GREEN or GREEN * Mask. In the end, wherever the mask is white, you get green, and wherever the mask is black, you get black.
Renderosity forum reply notifications are wonky. If I read a follow-up in a thread, but I don't myself reply, then notifications no longer happen AT ALL on that thread. So if I seem to be ignoring a question, that's why. (Updated September 23, 2019)