Re: Kajiya-Kay Hair Light Model
- From: Matt Pharr <matt@xxxxxxxxx>
- Date: Thu, 27 Oct 2005 20:00:48 GMT
"Ryan" <heniser@xxxxxxxxx> writes:
> Kajiya, J. T. and Kay, T. L. 1989. Rendering fur with three dimensional
> textures. In Proceedings of the 16th Annual Conference on Computer
> Graphics and interactive Techniques SIGGRAPH '89. ACM Press, New York,
> NY, 271-280. DOI= http://doi.acm.org/10.1145/74333.74361
>
> In their diffuse component derivation, I don't understand how they are
> able to simplify to Ks sin(t,l') in equations 14 on page 276. Will
> someone please enlighten me. Thank you.
Assuming I understand your question correctly, they're taking advantage of
the fact that cos^2 a + sin^2 a = 1 and the fact that the dot product
between two normalized vectors is equal to the cosine of the angle between
them (so sin a = (1-cos^a)/sqrt(1-cos^2 a) in this case.)
(Which leads to a useful general principle to keep in mind: when
implementing someone else's BRDF model, if your code ever calls asin(),
acos(), sin(), cos(), tan(), etc, explicitly, your code is almost certainly
suboptimal and could be implemented more efficiently via dot products and
taking advantage of various trig identities.)
-matt
--
Matt Pharr
matt@xxxxxxxxx
http://pharr.org/matt/
.
- References:
- Kajiya-Kay Hair Light Model
- From: Ryan
- Kajiya-Kay Hair Light Model
- Prev by Date: Re: etiquette of cgafaq.info/wiki
- Next by Date: Re: HELP: How to "TINT" bitmap?
- Previous by thread: Kajiya-Kay Hair Light Model
- Next by thread: Re: Kajiya-Kay Hair Light Model
- Index(es):
Relevant Pages
|