POV-Ray : Newsgroups : povray.general : CSG Union causes major slow-down : Re: CSG Union causes major slow-down Server Time
10 Aug 2024 01:24:22 EDT (-0400)
  Re: CSG Union causes major slow-down  
From: Ron Parker
Date: 24 May 2000 09:50:04
Message: <slrn8ino73.3kd.ron.parker@linux.parkerr.fwi.com>
On 24 May 2000 09:17:50 -0400, Warp wrote:
>Ron Parker <ron### [at] povrayorg> wrote:
>: It's represented as a merge.  There are special cases in the code for
>: merges.  IIRC, it could be represented as the inverse of the intersections
>: of the inverses of the constituent objects, but it isn't.
>
>  What is the algorithm for the ray-intersection test for merges (briefly
>and clearly exaplained, if possible :) )? I'm interested in knowing it.

1. Find all intersections.
2. Pop an intersection off the stack.  If none remains, no intersection
   with this object occurred.
3. Test to see if that intersection is inside any subobject other than the
   one it is on the surface of.  If so, throw it away and go to 2.
4. That's it.  Do whatever you do with the intersection you now have.  Don't
   forget to flush the stack, put the seat down, and turn off the light.

-- 
Ron Parker   http://www2.fwi.com/~parkerr/traces.html
These are my opinions.  I do NOT speak for the POV-Team.


Post a reply to this message

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