POV-Ray : Newsgroups : povray.binaries.images : yet another mengersponge... : Re: yet another mengersponge... Server Time
19 Aug 2024 02:28:57 EDT (-0400)
  Re: yet another mengersponge...  
From: David Fontaine
Date: 16 Mar 2001 17:38:03
Message: <3AB29534.A9C7D9A1@faricy.net>
Bonsai wrote:

> Not yet. Do you mean that I should bound smaller parts of the sponge per
> hand. Would this really decrease render time when I do the cut away?

Hmm, I'm not sure exactly how that worked. You split the CSG components into
however many groups, then those into however many smaller groups, etc, and bound
all the groups, with zero or minimal overlap of any two groups at the same
nesting level. Something like:

difference {
   box {}
   merge {
      merge {
         ...
         bounded_by {}
      }
      bounded_by {}
   }
   merge {
      merge {
         ...
         bounded_by {}
      }
      bounded_by {}
   }
   bounded_by {}
}

You could split it into 27 parts (3x3x3), each of the 20 edge parts splits
again... maybe it would be more efficient to split the x axis into three, then
the y, then the z, then start the next recursion level... Essentially you make a
bunch of nested bounding that serves to partition the space into smaller and
smaller pieces. It's very efficient because the intersection algorithim is
essentially "walking the tree". It might be tricky to get it arranged so that
you don't have coincident surfaces or anything.

--
David Fontaine  <dav### [at] faricynet>  ICQ 55354965
My raytracing gallery:  http://davidf.faricy.net/


Post a reply to this message

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