POV-Ray : Newsgroups : povray.advanced-users : smooth triangle Normal : Re: smooth triangle Normal Server Time
30 Jul 2024 12:19:41 EDT (-0400)
  Re: smooth triangle Normal  
From: Jerry Anning
Date: 9 Jun 1999 13:14:26
Message: <375ea028.2061215@news.povray.org>
On 9 Jun 1999 09:09:38 -0400, par### [at] fwicom (Ron Parker) wrote:

>On Wed, 09 Jun 1999 09:18:26 GMT, Jerry Anning wrote:
>>vnormalize(vcross(b-a, c-a)+vcross(c-a,d-a)+vcross(d-a,e-a)...)
>>Make sure that you are consistent in the sense (clockwise or
>>counterclockwise) in which you go around the vertex.
>
>You sure about that?  I think you might get some unintentional
>weighting in your average, making the resultant vector lean a bit
>towards the longer edges.  I would have thought you'd have to 
>normalize all the cross products first, then normalize the result.
>
>Of course, I haven't really thought about it, so I could be wrong.

Good catch, Ron.  You should indeed change vcross(b-a, c-a) etc. to
vnormalize(vcross(b-a,c-a)) if you want a robust result.  I tend to
forget about that because I usually do it to meshes where local edge
lengths are fairly constant.

Jerry Anning
clem "at" dhol "dot" com


Post a reply to this message

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