Disconnecting Glossy and Shadow

I’m trying to get this one sphere to appear grey, cast a grey shadow, but reflect as blue when looking into a mirror.

So far I’ve managed to get it to look grey, but it still casts a blue shadow. I can’t isolate the shadow away from the glossy so I can affect the color of all 3.

Here’s a photo of my node setup.


That’s not a blue shadow, that’s the reflection of the sphere on a non-glossy surface.

That’s why you get the blue in areas where you don’t want it, you might want to try to use outputs like ray depth and nodes like camera data to tighten the criteria for that blue color.

The ground plane is unfortunately glossy, otherwise it doesn’t look that good. Is there a way to tell the ground plane not to reflect blue and the sphere to reflect blue?

I’m don’t think Cycles actually has anything that can separate effects based on object groups (which works independent of which object has what material). You might have to look into compositing and making use of the object and material index passes.

I also know that there’s the object data node, but I’m not sure how much of a help that would be since you can’t actually type in the name of an object. 2.73 also will have something known as object coordinates (available through the texture coordinate node), but I haven’t use it yet so I can’t say if it can be used as a proximity mask.

A third way would simply be a procedural mask you make out of a blend texture and patch it over the blue shadow (the node setup would be then that the texture value can prevent the mix with blue).

Well I plugged in the ray depth, and came out with this. Closer, but still not what I’m looking for.


Yeah I had thought of that, kinda preferred to do it in the material, but might have to go that route.

Wait a sec. I turned the ground into a diffuse material, but the blue “shadow” is still there. Where is that coming from? The other sphere? Why is it pooling in one spot?


Color bleeding (part of GI). The sphere also appears blue to diffuse rays, so the sphere casts blue-tinted GI.

A little workaround:
Duplicate the glossy sphere, scale it up a little and give it a transparent material.
Then uncheck “Properties -> Object -> Ray Visibility -> Camera” !!! see screenshot to understand why !!!
Give the grey sphere a mix material with grey diffuse and blue diffuse mix factor = “Light Path -> Transparent Depth”

EDIT: you don’t have to use 2 diffuse nodes. Use 1 diffuse node and a color mix node with the transparent depth as mix factor.

For more information about the light path node watch this tutorial:
https://www.youtube.com/watch?v=MTFxyNzI5EE

Hope this helps.