lorduk Posted August 21, 2003 Share Posted August 21, 2003 Have few questions about ray-tracing in mantra.... First of all many raytraces have controlls how many times a ray can reflect/refract - how is this controlled in mantra? secondly if I use rayhit vops on fully opaque object ex. plastic sphere with P and I then the distance returned would be the thickness of the sphere at the point? need all this to get good transparancy for liquids (it took me a wile to figure out how to do decent refraction ) -Kaspar Quote Link to comment Share on other sites More sharing options...
stevenong Posted August 21, 2003 Share Posted August 21, 2003 Hi Kaspar, First of all many raytraces have controlls how many times a ray can reflect/refract - how is this controlled in mantra? Please go to the Render tab of the object and the options you're looking for are "Ray Bounce" and "Ray Clip" (Houdini 5.5 and below) or "Reflect Bounce", "Refract Bounce" and "Ray Clip" (Houdini 6.0 and above). As for your second question, I'll leave it to someone more knowledgable than me to answer it. I hope to see the liquids you're working on though. Cheers! steven Quote Link to comment Share on other sites More sharing options...
lorduk Posted August 22, 2003 Author Share Posted August 22, 2003 Ok that cleared on thing up for me, but how does ray-tracing work I mean the ray level 0 hits the surface point P, the point P shader says trace to direction I, so ray level 1 hist a surface point P1 and P1 has the same shader as P so the tracing would go on untill reflect/refract bounce level is achived or P with no ray-tracing is hit!? if it is so... then when I use rayhit vops distance returned would be P to P1, P to Px or even Px-1 to Px Maybe there is a good source on the internet about ray tracing, baecuse I have advanced renderman book and I cant figure it out for renderman as well (and I have lost my copy of BMRT so cant test it either) -Kaspar edit: c'mon I know there are some phunky ray mongers around, who can help me Quote Link to comment Share on other sites More sharing options...
lorduk Posted September 2, 2003 Author Share Posted September 2, 2003 I have lost all hope -> so I turned to documentation but the things get starger.... Note: Though it is possible, in many cases, the area sampling features will not produce usable results with the rayhittest() function. what do they mean by that? that I cant preform volume measurements with rayhittest(), then how? ohh an a test render as well: -Kaspar Quote Link to comment Share on other sites More sharing options...
AndrewVK Posted September 2, 2003 Share Posted September 2, 2003 Hmmm...actualy You can. Rayhittest will return the distance to the !!!FIRST!!! object intersected. So...forget about bounce level To make sure that you trace volume of current object use construction like this: string myname = getobjectname(); float depth = rayhittest(P, normalize(I) * maxdist, bias, "scope", myname); Quote Link to comment Share on other sites More sharing options...
lorduk Posted September 2, 2003 Author Share Posted September 2, 2003 but that is exactly what I am doing, 1. pic is opaque surface 2. pic is the translucant surface 3. pic is the outcome of the ray hit test (it seems ok dosen't it!?) 4. colormix(2,1,3) -> now that is totally bogus, but when I use solid color or anything without ray-tracing it is OK... so what is up with that -Kaspar edit: here's a taught maybe I should limit rayhit test to be used only on primary rays, so the transparency would not be re-calculated on reflected and refracted P's? This seemed to do the trick Quote Link to comment Share on other sites More sharing options...
lorduk Posted September 4, 2003 Author Share Posted September 4, 2003 Ok, mostly I am done with the shader but is there a simple formula for little ray jitter -> so I can multisample rayhittest (with a single sample getting really bad aliasing -> black dots all over the place ) -Kaspar Quote Link to comment Share on other sites More sharing options...
AndrewVK Posted September 4, 2003 Share Posted September 4, 2003 IMHO AreaSampling + Rahittest = NONSENCE Try to increase "bias" value. Also...hmmm.... "If no object is hit, the distance will less than 0" This is very important in the case of selfhittesting and this can cause truble. 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.