POV-Ray : Newsgroups : povray.general : difference problem w/3.1 : Re: difference problem w/3.1 Server Time
13 Aug 2024 15:30:39 EDT (-0400)
  Re: difference problem w/3.1  
From: Ron Parker
Date: 5 Oct 1998 12:03:49
Message: <3618dfd5.0@news.povray.org>
On 5 Oct 1998 10:47:53 -0500, Nieminen Mika <war### [at] assaricctutfi> wrote:
>Ken <tyl### [at] pacbellnet> wrote:
>:     So the program sees a situation where the csg operation
>: is going to have perfectly aligned surfaces.
>
>  I want to see that function, which takes any two objects and checks if
>they have coincident surfaces (note that the coincidence doesn't have to
>be 2-dimensional, it may occur also in a 1-dimensional line (which causes
>random black dots along this line)). For example it would check if a
>7th order poly object and a blob have a coincident surface... Or a lathe
>object and a bezier patch... :)

Well, one could argue that if the first two intersections it finds while
tracing rays are within a specified tolerance, then it should kick into 
"coincident surfaces resolution mode," but it's not entirely clear what 
it should do in each case.  I think it would have to walk the CSG tree 
and determine which operation the two objects found have in common at
the lowest level, then decide whether there's really an intersection 
there or not, and if there is which surface it should intersect with.
Then, of course, it should store that decision so it always reaches
a consistent conclusion when it hits that particular pair of surfaces.
(Meaning: if it hits it from the same direction, use the same surface;
if it comes from the other direction, use the other one.)

How to decide if there's really an intersection there?  If the common
operation is intersection, should we throw the intersection away or
keep it?  I think this depends on whether we're entering both objects,
leaving both objects, or entering one and leaving another.  In the
first two cases, keep it.  In the last case, throw it away.  For
union, always keep it.  For merge, keep it using the same criteria 
as for intersection.  Difference, of course, does not exist as a CSG
type, but the proposed intersection rules seem to do the right thing.


Post a reply to this message

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