soroush Posted March 4, 2017 Share Posted March 4, 2017 Hello everyone, Anyone has any idea that what is the best way to get AO from a closed space that lights can't pass trough? Imagine a room without any windows. If I put a light inside the room the result will be shadows instead of AO. And If I put an ENV light, it will be black unless I un-check the casting shadows which it makes everything white. Thanks Quote Link to comment Share on other sites More sharing options...
symek Posted March 4, 2017 Share Posted March 4, 2017 You could use Occlusion VOP in your surface material. Remember to change max distance from -1 to something close to an interior size (otherwise every ray hit will be treated as an occlusion == black render). Also Background color has to be set to 2.0. 1 Quote Link to comment Share on other sites More sharing options...
soroush Posted March 4, 2017 Author Share Posted March 4, 2017 7 hours ago, symek said: You could use Occlusion VOP in your surface material. Remember to change max distance from -1 to something close to an interior size (otherwise every ray hit will be treated as an occlusion == black render). Also Background color has to be set to 2.0. I am pretty new in Houdini. Where do I have to connect the Occlusion VOP to? and also how do I get it out in my passes? any special setting do I have change in my render settings? Quote Link to comment Share on other sites More sharing options...
6ril Posted March 4, 2017 Share Posted March 4, 2017 the answer to all those questions would be writing a part of the software doc ! I suggest you start with the basics, tuts on sidefx etc... Quote Link to comment Share on other sites More sharing options...
soroush Posted March 5, 2017 Author Share Posted March 5, 2017 2 hours ago, 6ril said: the answer to all those questions would be writing a part of the software doc ! I suggest you start with the basics, tuts on sidefx etc... the question might be basic but I can't spend like months to read all the docs now to find the answer. My scene is ready to render so I thought maybe there is an easy and quick method to do it, specially because the situation in my scene is something unusual as the space is a closed space. I am learning Houdini, and asking a question here doesn't mean I don't google things or I don't look at the Houdini docs. Thanks anyway Quote Link to comment Share on other sites More sharing options...
6ril Posted March 5, 2017 Share Posted March 5, 2017 didn't know you got a scene ready, and re-reading myself now, I sound a little harsh, sorry about that. are you comfortable with mantra shader building/modifying ? render aovs ? Can't really help you now, and I haven't used mantra for like a year now, but I'm sure someone will help you, implementing AO shouldn't be a big pb. Quote Link to comment Share on other sites More sharing options...
f1480187 Posted March 5, 2017 Share Posted March 5, 2017 In Houdini 16 set material flag on the Occlusion node placed inside /mat context and use it as the material. To make the same in SHOPs, drop Material Shader Builder and connect Occlusion to Cf. occlusion.hipnc 1 Quote Link to comment Share on other sites More sharing options...
soroush Posted March 5, 2017 Author Share Posted March 5, 2017 5 hours ago, 6ril said: didn't know you got a scene ready, and re-reading myself now, I sound a little harsh, sorry about that. are you comfortable with mantra shader building/modifying ? render aovs ? Can't really help you now, and I haven't used mantra for like a year now, but I'm sure someone will help you, implementing AO shouldn't be a big pb. no problem man, I totally understand you and I know that my question is something that soppose to be simple. but I just can't get it right! I am ok to modify the shaders but not like a pro, cuz I came from 3ds max and Maya background. I can get the AO right for any objects. but when I have the objects inside another objects, everything will be black. Quote Link to comment Share on other sites More sharing options...
soroush Posted March 5, 2017 Author Share Posted March 5, 2017 3 hours ago, f1480187 said: In Houdini 16 set material flag on the Occlusion node placed inside /mat context and use it as the material. To make the same in SHOPs, drop Material Shader Builder and connect Occlusion to Cf. occlusion.hipnc Thank you for your help, I don't have access to Houdini 16 and I am working with houdini 15.5. I have opened your file and it is not giving me the AO. I have actually tried this way and couldn't get an AO from it. I have tried many methods from yesterday and non of them works for me. specially when I have an objects inside a closed object. (I know your example is like that also but it doesn't work for me :| ) Quote Link to comment Share on other sites More sharing options...
6ril Posted March 5, 2017 Share Posted March 5, 2017 @soroush it does work, but I guess since it comes from H16, you loose the material tab on the box object. So get inside box1, add a material node at the end, and select the /shop/vopmaterial1. Don't forget to put the display flag on that new node that's it, just hit render and see the occlusion, you can then play with the param of the occlusion node in Shop max ray distance : the spreading of the occlusion background color : intensity of the "light" Quote Link to comment Share on other sites More sharing options...
anim Posted March 5, 2017 Share Posted March 5, 2017 you can just use Env Light in AO mode there is Max Ray Distance slider there as well Quote Link to comment Share on other sites More sharing options...
soroush Posted March 5, 2017 Author Share Posted March 5, 2017 2 hours ago, 6ril said: @soroush it does work, but I guess since it comes from H16, you loose the material tab on the box object. So get inside box1, add a material node at the end, and select the /shop/vopmaterial1. Don't forget to put the display flag on that new node that's it, just hit render and see the occlusion, you can then play with the param of the occlusion node in Shop max ray distance : the spreading of the occlusion background color : intensity of the "light" It is working now! I do remember I have tried it before and was not working! I have created a new scene with a new shader yesterday, same as what you did and was nor working! gonna try it in my scene now. Thanks a lot Cyril! Quote Link to comment Share on other sites More sharing options...
soroush Posted March 5, 2017 Author Share Posted March 5, 2017 20 minutes ago, anim said: you can just use Env Light in AO mode there is Max Ray Distance slider there as well Thank you Tomas, But I don't think if the method with ENV light works in my situatio. Quote Link to comment Share on other sites More sharing options...
anim Posted March 5, 2017 Share Posted March 5, 2017 what do you mean? Diffuse shader and env light, then tweak the distance to be small enough, that should work Quote Link to comment Share on other sites More sharing options...
soroush Posted March 5, 2017 Author Share Posted March 5, 2017 1 hour ago, anim said: what do you mean? Diffuse shader and env light, then tweak the distance to be small enough, that should work I am not sure, cuz when I tried with ENV light it does give me a black result because it is a closed environment, so there is not any place for the ENV light to pass trough my space. Quote Link to comment Share on other sites More sharing options...
anim Posted March 5, 2017 Share Posted March 5, 2017 you are misunderstanding what Env Light in AO Mode does, just try what I said, or just look at this file AO_light_inside.hip Quote Link to comment Share on other sites More sharing options...
soroush Posted March 6, 2017 Author Share Posted March 6, 2017 2 hours ago, anim said: you are misunderstanding what Env Light in AO Mode does, just try what I said, or just look at this file AO_light_inside.hip OH! I got it now! I think the problem that I was keep getting black result was that the number of Max RA Distance was too high by defult. Thanks Man! That is working now! Cyril Method works also! Quote Link to comment Share on other sites More sharing options...
soroush Posted March 6, 2017 Author Share Posted March 6, 2017 6 hours ago, 6ril said: @soroush it does work, but I guess since it comes from H16, you loose the material tab on the box object. So get inside box1, add a material node at the end, and select the /shop/vopmaterial1. Don't forget to put the display flag on that new node that's it, just hit render and see the occlusion, you can then play with the param of the occlusion node in Shop max ray distance : the spreading of the occlusion background color : intensity of the "light" I know it is stupid! the problem that I was always getting the black result was that I didn't change the background color and it was always Black so it was not generating any lights! Thanks man. Everything works great now! Quote Link to comment Share on other sites More sharing options...
6ril Posted March 6, 2017 Share Posted March 6, 2017 glad to hear even tho it's f1480187 who unstuck you f1480187 the unstucker ! got a problem? press the f1480187 key ! Quote Link to comment Share on other sites More sharing options...
soroush Posted March 6, 2017 Author Share Posted March 6, 2017 Thanks to F1...... as well hehe Yeah, Gonna add that button here on my keyboard. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.