spice Posted December 13, 2004 Share Posted December 13, 2004 OK, this format should be possible, but I would prefer more compact binary data. Currently I Quote Link to comment Share on other sites More sharing options...
spice Posted December 13, 2004 Share Posted December 13, 2004 Just to give you an idea what near field means (an extreme close-up of two hairs).... right: Marscheners model left: (my) near field model (with indirect illumination) Quote Link to comment Share on other sites More sharing options...
serge Posted December 13, 2004 Share Posted December 13, 2004 Arno, Never saw the Schlick approximation before but I just got ahold of his paper from 1994 and intend to read it at some point. Looks like the approximation formula is in there and I can make an implementation from that. As for theta there looks to be one set of them in my calculations, all based on the exterior incident angles between the hair and the eye and the hair and the light. I don't have a seperate set for the interior of the hair. It was my impression that the exterior theta determines the effective index of refraction that is used to make the subsequent calculations possible in the normal plane of the hair. And that whatever calculations need to be made, including the fresnel calculations, could be done using this effective index of refraction. Why do you ask, have you found a need for the internal incidence angle? As for pictures, it would probably be best to get your hair sample (along with the lighting you used). Currently all of the tests that are being run are using models specific to the film project we are working on and I am not at liberty to post them (as much as I'd like to). Cheers! Serge Hi Serge,im in a hurry so I have not enough tiime to answer your question in detail... I think you use the Fresnel-Schlick approximation, right ?! The difference is not that big compared to the "real" Fresnel equation... But if you are interested, I could sent you the C-source of my optimized "real" Fresnel function... How do you calculate theta_t (the "inclination inside the hair") ??? Cheers! Arno 15439[/snapback] Quote Link to comment Share on other sites More sharing options...
spice Posted December 13, 2004 Share Posted December 13, 2004 Why do you ask, have you found a need for the internal incidence angle? ...As for pictures, it would probably be best to get your hair sample (along with the lighting you used). Currently all of the tests that are being run are using models specific to the film project we are working on and I am not at liberty to post them (as much as I'd like to). Cheers! Serge 15493[/snapback] Hi Serge, you DO need an additional theta inside the hair to compute absorption correctly !!! The modified index of refraction is used ONLY to compute the "projected path" (within the normal plane). Of course I can send you my geometry. But I Quote Link to comment Share on other sites More sharing options...
serge Posted December 14, 2004 Share Posted December 14, 2004 Quite right. I'm just using the plain old external theta there too. I guess now would be time to take another look at the absorbtion formula given this and your other correction to it. Cheers! Serge Hi Serge,you DO need an additional theta inside the hair to compute absorption correctly !!! The modified index of refraction is used ONLY to compute the "projected path" (within the normal plane). Of course I can send you my geometry. But I Quote Link to comment Share on other sites More sharing options...
spice Posted December 14, 2004 Share Posted December 14, 2004 Quite right. I'm just using the plain old external theta there too. I guess now would be time to take another look at the absorbtion formula given this and your other correction to it.Cheers! Serge 15495[/snapback] Should we try my (Marschener implementation) code with your renderer ?? :-) Quote Link to comment Share on other sites More sharing options...
Mario Marengo Posted December 14, 2004 Share Posted December 14, 2004 Never saw the Schlick approximation before but I just got ahold of his paper from 1994 and intend to read it at some point. Looks like the approximation formula is in there and I can make an implementation from that. 15493[/snapback] Hey serge, I just thought I'd chime in in case this is of use to you: I've started sketching some info on BRDFs at the wiki, and toward the end of the page you'll see a half-finished entry on the Fresnel equations -- these are for the reflection factor for unpolarized light, including Schlick's approximation. Cheers, and good luck with this hair thing! Quote Link to comment Share on other sites More sharing options...
serge Posted December 14, 2004 Share Posted December 14, 2004 Well, let me bounce this off of you. It would seem to me that the actual ray that penetrates into the hair forms a right triangle with it's projection in the normal plane and the wall of the hair. The relationship between the radius and the length of the penetrating ray is 1 / cos(theta_t). So your corrected ray path length would go from 2*cos(gamma_t) to 2*cos(gamma_t)/cos(theta_t). And since theta_t=arcsin(eta)*theta_i the whole path length in terms of gamma_t and theta_i would be: 2*cos(gamma_t) / cos(arcsin(eta) * theta_i) What do u think? Serge Should we try my (Marschener implementation) code with your renderer ?? :-) 15496[/snapback] 1 Quote Link to comment Share on other sites More sharing options...
edward Posted December 14, 2004 Share Posted December 14, 2004 OK, this format should be possible, but I would prefer more compact binary data. Currently I Quote Link to comment Share on other sites More sharing options...
spice Posted December 14, 2004 Share Posted December 14, 2004 Well, let me bounce this off of you. It would seem to me that the actual ray Quote Link to comment Share on other sites More sharing options...
spice Posted December 14, 2004 Share Posted December 14, 2004 I wasn't suggesting that you switch to this format but merely to add a format for your renderer. I think it will help you in the future to be able render geometry output from another source anyhow. For the purposes of exchange, I think it's the easiest way.The nice thing about .PLY is that there's already large academic repository of models. Plus, imagine the ability to process geometry in Houdini. 15499[/snapback] Yes, that Quote Link to comment Share on other sites More sharing options...
Jason Posted December 14, 2004 Share Posted December 14, 2004 So if anybody out there wants sophisticated "state of the art" hair visualization dont hesitate to contact me 15503[/snapback] You'll surely get a large response from this community right here with a great desire to see the shader implemented in Mantra. As for paying customers... Quote Link to comment Share on other sites More sharing options...
serge Posted December 14, 2004 Share Posted December 14, 2004 Yes, a little mistake in my algebra. At least my heart is in the right place. As for the faster formula, I assume you are refering to the Snell's law approximation that is in the paper. Regarding the geometry you can send it to me. I'll see what I can do with it but I may need Jason's help for the conversion and he's out I think for the rest of this week. Cheers! and thanks again. Serge Yes Serge, in principle your idea is right, but:theta_t=arcsin(sin(theta_i)/eta) -> cos(theta_t) =cos(arcsin(sin(theta_i)/eta)) !! But if you think hard enough, you might find a formula, which does the same, but can be computed MUCH faster.... Is there anything else, you Quote Link to comment Share on other sites More sharing options...
spice Posted December 14, 2004 Share Posted December 14, 2004 As for the faster formula, I assume you are refering to the Snell's law approximation that is in the paper. Hi Serge, hope we see some results of your shader soon ?! No, I was not refering to the approximation Snell Quote Link to comment Share on other sites More sharing options...
spice Posted December 15, 2004 Share Posted December 15, 2004 You'll surely get a large response from this community right here with a great desire to see the shader implemented in Mantra. As for paying customers... 15505[/snapback] OK, they are welcome By the way: Does Mantra support a "real" cylinder primitive ? For my near field shader I need to know, where an eye ray hits the minimal enclosing cylinder (just the first intersection normal) of a hair segment. Cheers ! Arno Quote Link to comment Share on other sites More sharing options...
Jason Posted December 17, 2004 Share Posted December 17, 2004 OK, they are welcome By the way: Does Mantra support a "real" cylinder primitive ? For my near field shader I need to know, where an eye ray hits the minimal enclosing cylinder (just the first intersection normal) of a hair segment. Cheers ! Arno 15520[/snapback] I'm afraid not - I believe you'll have to calculate it yourself from the ribbon (curve) primitive. Quote Link to comment Share on other sites More sharing options...
spice Posted December 17, 2004 Share Posted December 17, 2004 Some other results rendered with my near field shader (simple raytracing)... left: brown hair, right: blond hair (top: one distant front light, bottom: one distant back light) Cheers! Arno Quote Link to comment Share on other sites More sharing options...
deecue Posted December 17, 2004 Share Posted December 17, 2004 Some other results rendered with my near field shader (simple raytracing)... left: brown hair, right: blond hair (top: one distant front light, bottom: one distant back light) Cheers! Arno 15551[/snapback] is this mantra? Quote Link to comment Share on other sites More sharing options...
spice Posted December 18, 2004 Share Posted December 18, 2004 is this mantra? 15558[/snapback] No, not yet (it Quote Link to comment Share on other sites More sharing options...
spice Posted December 28, 2004 Share Posted December 28, 2004 Jason has convinced me to publish a VEX version of my hair shader. I already converted the surface shader function, but since I 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.