POV-Ray : Newsgroups : povray.general : Minimum Distance Function : Re: Minimum Distance Function Server Time
15 Aug 2022 08:48:10 EDT (-0400)
  Re: Minimum Distance Function  
From: Cousin Ricky
Date: 10 Jul 2022 20:14:52
Message: <62cb6b7c@news.povray.org>
On 2022-07-10 15:27 (-4), jceddy wrote:
> 
> So I got the code to calculated minimum distance using nearest-vertex from a
> kd-tree working. At least I think so...I have some tiny artefacts that I think
> might be a result of a bug in the code, but might also just be a result of the
> kinds of tolerance issues that were mentioned above.
> 
> I added code to the underlying Mesh object in povray for calculating a
> transformed copy of the vertex data, and verified that that seems to be
> working...but now thinking there might be an easier solution. Like...
> 
> Can I inverse-transform the point being tested, run the minimum-distance
> calculation against the original data to get a minimum-distance *VECTOR* from
> the test point to the original mesh, then just apply the object's transformation
> matrix to that vector before measuring its length?

It's been almost 40 years, so I don't remember why, but I seem to recall
learning in university that inverse transformations take a heavy toll on
numeric precision.


Post a reply to this message

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