POV-Ray : Newsgroups : povray.general : Calculate normal vector? : Re: Calculate normal vector? Server Time
1 Aug 2024 20:13:23 EDT (-0400)
  Re: Calculate normal vector?  
From: Thorsten Froehlich
Date: 26 Sep 2008 02:12:58
Message: <48dc7d6a$1@news.povray.org>
B. Gimeno wrote:
> Greetings,
> I hope that no one feels annoyed about this repetitive question automatically
> translated, but I'm stuck at the point of finding the normal to a given
> triangle. I've read and re-read the answers given in this forum but I keep
> stopping with this.
> 
> A triangle whose vertex are generated by a nested while-loop. (v1,v2,v3)
> 
> I attempt to find the normal by normalizing the product of vectors:
> 
> #local N = vnormalize(vcross( (v2 - v1) , (v3 - v1) ))  ;
> 
> Then I apply the normal obtained to a smooth_triangle, and the result is uh....
> unsmoothed_triangles.
> 
> smooth_triangle {v1,N,v2,N,v3,N}

What do you expect if all normals are identical? - For a single triangle 
this will never be different...

	Thorsten


Post a reply to this message

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