Ambient Occlusion only in shadowed Areas?

Discussions regarding Materials, Material-Compounds or Shaders, etc.
artmanphil
Posts: 19
Joined: 28 Mar 2011, 10:03
Skype: artmanphil

Ambient Occlusion only in shadowed Areas?

Post by artmanphil » 27 Oct 2012, 18:30

Hey Kids,
I'm looking for a way to make ao only appear in shadowed/darkened areas (which is closer to reality than ao on everything). "Do it in comp" they say - maybe a good idea, still there must be a way to produce an intelligent shader doing this for me.

My first approach was Mix 2 Colors with "multiply", ao in second color, shadow shader as weight.
Doesn't work :( Ideas?

User avatar
Mathaeus
Posts: 1778
Joined: 08 Jun 2009, 19:11
Location: Zagreb, Croatia

Re: Ambient Occlusion only in shadowed Areas?

Post by Mathaeus » 27 Oct 2012, 19:47

something like that should work. Probably you need to try a bit more, let's say, just a mix of AO and white color, then multiply entire diffuse shader with this. Take look at options in shadow shader, too. By default SI shadow shader outputs only alpha. Mix2 colors in multiply mode, works a bit different than Photoshop multiply - weight in SI mix2colors is actually multiplier, small weight makes a darker mix.

artmanphil
Posts: 19
Joined: 28 Mar 2011, 10:03
Skype: artmanphil

Re: Ambient Occlusion only in shadowed Areas?

Post by artmanphil » 28 Oct 2012, 14:30

Harr I found a solution:

Plug Diffuse into Mix2Colors (Base Color) and in AO (bright color).
AO into same Mix2Colors (color1).
Shadow Shader (rgb checked) into Weight.

Looks really cool :D