POV-Ray : Newsgroups : povray.advanced-users : Can't figure out a formula! : Re: Can't figure out a formula! Server Time
30 Jul 2024 14:27:06 EDT (-0400)
  Re: Can't figure out a formula!  
From: Nieminen Mika
Date: 20 May 1999 11:49:34
Message: <374420fe.0@news.povray.org>
Ron Parker <par### [at] fwicom> wrote:
:   #local n=vnormalize(vcross((b)-(a),(c)-(a)));

  You don't need to normalize the vector since the length of the vector
doesn't matter. Normalizing only makes parsing slower.
  Of course if you use the normal vector for example in a matrix to
transform the object/texture then you need to normalize it.

  Btw. The matrix transformation calculated from the normal vector is
much better then using the angle. For more info see:
http://www.erols.com/vansickl/matrix.htm

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.