POV-Ray : Newsgroups : povray.advanced-users : Intersection Testing in #while loops. : Re: Intersection Testing in #while loops. Server Time
30 Jul 2024 04:11:02 EDT (-0400)
  Re: Intersection Testing in #while loops.  
From: PoD
Date: 10 Mar 2000 14:33:50
Message: <38C9528C.CBB5E10E@merlin.net.au>
Ken wrote:
> 
> If I create a group of objects with a while loop
> 
> #declare Thing =
> union {
>  #declare a = 0;
>    #while (a<10)
>      #declare b = 0;
>        #while (b<10)
>          sphere{<a,b,0>,1}
>        #declare b=b+1;
>      #end
>    #declare a=a+1;
>  #end
> }
> 
> and then intersected my new object Thing with a plane
> 
> intesection {
>  object{ Thing }
>   plane {y,0 }
> }
> 
> would the intersection testing be done only to those objects that the
> plane actually comes in contact with or would the intersection testing
> be done against every object in the object Thing ?
> 
> --
> Ken Tyler -  1300+ Povray, Graphics, 3D Rendering, and Raytracing Links:
> http://home.pacbell.net/tylereng/index.html http://www.povray.org/links/

Good question. I suspect that all objects will be tested for
intersection.
It should be possible during parsing to test whether objects in an
intersection will actually intersect, at least for simple primitives.

PoD.


Post a reply to this message

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