View Full Version : Marschner Hair
rendermaniac 03232006, 12:26 AM Just noticed this post from a familiar name ;) After reading the Marschner paper I was thoroughly confused about the azimuth scattering too.
http://odforce.net/forum/index.php?showtopic=2208&st=144
Surely if we have we have phi (azimuth angle between light and viewer), we need to work out what incident angle contributed to it (as a h value). But there will only be one of these for R and TT (TRT is another matter) so it's not immediately obvious where dphi and dh come from and how they should be used.
Anyway seeing as I don't understand this either I thought I would ask this here as well as Ander's post on odforce.
By the way there are some mistakes to do with the absorbtion and Fresnel falloff in the original paper which have the corrections in this thread from Arno Zinke which is extremely helpful.
Simon


playmesumch00ns
03232006, 09:49 AM
Yes, that paper is an absolute arse. Probably even worse than Jensen's original subsurface paper.
The basic gist of it is this:
1) Calculate gamma_i by solving the cubic equation (10), use this to get gamma_t
2) Differentiate equation (3) symbolically to get expressions for dPhi_dh and d2Phi_dh2
3) Plug in the values of gamma_i and gamma_t to the equations from step 2
4) Debug for a week until you iron out all the bugs :)
Mauritius
03242006, 07:03 AM
Yes, that paper is an absolute arse. Probably even worse than Jensen's original subsurface paper.
Yeah, and what pisses me off most is actually that we have to do it all again and again. Why are we not allowed to share this stuff?
I guess that at every mayor VFX house probably has an implementation of that BRDF. And for every one of these, a TD spent a week or two doing this shit. Crap!
Cheers,
Moritz
rendermaniac
03242006, 08:36 AM
Yes, that paper is an absolute arse. Probably even worse than Jensen's original subsurface paper.
The basic gist of it is this:
1) Calculate gamma_i by solving the cubic equation (10), use this to get gamma_t
2) Differentiate equation (3) symbolically to get expressions for dPhi_dh and d2Phi_dh2
3) Plug in the values of gamma_i and gamma_t to the equations from step 2
4) Debug for a week until you iron out all the bugs :)
I may be missing the point here, but I thought you calculate gamma_i from the cubic, then calculate h from it, substitute it into 3, then get the differential of that??
Seems like 2003 was a good year for papers  a really bad year for being able to comprehend them!
There do seem to be some people who are good at presenting stuff  although it tends to come from people actually using it in production  eg the RenderMan coursenotes and papers from the Game Developers Conferences.
Simon
playmesumch00ns
03242006, 12:44 PM
Yep you're right, I just formulated it in terms of sin_gamma_i myself since that's what you want to use when you differentiate.
I much prefer reading the GDC papers, there seems to be much less academic bullshit in those things.
What I hate most about siggraph papers is when the authors either leave out core implementation details, or leave in seemingly deliberate mistakes. Like they're testing you to see if you're "worthy" of using their research.
cosmonaut
03242006, 08:25 PM
I've been working on implementing this shader too and have run into some of the same problems. Does anyone know if there are any implementations out there with source code? I've done a bunch of google searchs but haven't turned up anything (just a bunch of gdc papers from nvidia and ati)
rendermaniac
03242006, 10:31 PM
The only practical reference to it I found was in GPU Gems 2 where they used it for the Nalu Nvidia demo. However they precalculated a texture and just said "refer to the paper for the details". It does give information on calculating theta, phi etc.
Simon
CGTalk Moderation
03242006, 10:31 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©20002014, Jelsoft Enterprises Ltd.