POV-Ray : Newsgroups : povray.unofficial.patches : Patch enhancement request - Trace keyword : Re: Stacking spheres - was Re: Patch enhancement request - Trace keyword Server Time
2 Sep 2024 08:15:57 EDT (-0400)
  Re: Stacking spheres - was Re: Patch enhancement request - Trace keyword  
From: Ron Parker
Date: 30 Jun 2000 16:59:48
Message: <slrn8lq388.1vi.ron.parker@linux.parkerr.fwi.com>
On Fri, 30 Jun 2000 13:59:58 -0700, SamuelT wrote:
>Chris Huff wrote:
>
>> It might work better if you added the objects to an array intead of
>> using a deeply nested union.
>
>Darn, haven't learned arrays yet. What would I do with the array?

Put your spheres in it and loop over the ones you have so far looking for
a hit with trace().  Then take the closest hit you found.  The nested unions
are probably faster, if you can get them to work.

>> Oh, and why did you use "#object"?
>
>I thought I had to encase Obj inside it....

You're looking for "object" rather than "#object".  "#object" is bad syntax,
but the parser treats it like "object" for now.

-- 
Ron Parker   http://www2.fwi.com/~parkerr/traces.html
My opinions.  Mine.  Not anyone else's.


Post a reply to this message

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