POV-Ray : Newsgroups : povray.binaries.images : For Hugo. Irregular mesh smoothing idea. : Re: Does this look right to you, ABX? Server Time
16 Aug 2024 14:20:45 EDT (-0400)
  Re: Does this look right to you, ABX?  
From:
Date: 7 Mar 2002 02:57:04
Message: <t47e8ugr5d8n0bucu9tu5la1fsrgbc4mel@4ax.com>
On Wed, 6 Mar 2002 12:45:09 -0600, "Shay" <sah### [at] simcopartscom> wrote:
> > #local triangle_area_engine=function{(x+y+z)*(y+z-x)*(x+y-z)*(x+z-y)/16}
> > #local triangle_area=
> >   function(x1,y1,z1,x2,y2,z2,x3,y3,z3)
> >     {sqrt(triangle_area_engine(
> >         f_r(x2-x1,y2-y1,z2-z1),
> >         f_r(x3-x2,y3-y2,z3-z2),
> >         f_r(x3-x1,y3-y1,z3-z1)
> >     ))};
>
> #include "functions.inc"
> #local triangle_area_engine=function{(x+y+z)*(y+z-x)*(x+y-z)*(x+z-y)/16}
> #local Triangle_Area =  triangle_area_engine(Side_1_Length, Side_2_Length,
Side_3_Length);
>
> Seems right to me, but I might be missing something.

You forgot about sqrt applied but since others mentioned that not normalized
cross product is sufficient then I think my method is wasting of pov-time ;-)

ABX


Post a reply to this message

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