POV-Ray : Newsgroups : povray.general : Testing whether a shape intersects with another : Re: Testing whether a shape intersects with another Server Time
31 Jul 2024 04:20:01 EDT (-0400)
  Re: Testing whether a shape intersects with another  
From: PhilipIsPDR
Date: 4 Nov 2007 11:05:00
Message: <web.472decd3cc25c29c5a2aacfe0@news.povray.org>
Jan Dvorak <jan### [at] centrumcz> wrote:
> M_a_r_c napsal(a):

> > web.472dcf35dc25d7085a2aacfe0@news.povray.org...
> >> Does anyone know a way of accomplishing this?  I've looked and looked, and
> >> I
> >> realise I might be missing something very obvious...
> >>
> > What is obvious is that you did not make a research about the word "inside"
> > in the pov documentaion :-)
> >
> > Marc
> >
> >
> what is obvious is that you missed he doesn't test for a point. He tests
> for an object being inside another.
>
> One idea is to choose a point where the inner surface is seen completely
> when unoccluded and then trace it together with the other object. If all
> of your rays hit the object you know it's not being intersected by the
> other object, hoping not to miss anything. Then use inside() to know
> whether it is completely inside or completely outside. There is no
> general algorithm to find out if two objects have non-null intersection.


Jan, thank you very much for this suggestion, I think I'm going to go with
something very similar to this.

Philip


Post a reply to this message

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