POV-Ray : Newsgroups : povray.advanced-users : Superellipsoids not very efficient? : Re: Superellipsoids not very efficient? Server Time
28 Jul 2024 16:17:56 EDT (-0400)
  Re: Superellipsoids not very efficient?  
From: Mike Williams
Date: 9 Nov 2004 00:52:14
Message: <kC$KvCAQlFkBFwr3@econym.demon.co.uk>
Wasn't it Mike Thorn who wrote:
>
>I am cutting a hole in the middle of the whole group of them.
>

That'll be what's making it slow. It's the same sort of situation that's
covered in my holes tutorial <http://www.econym.demon.co.uk/holetut> but
inside out. One large hole in a union of many small objects, rather than
many small holes in one large object.

What happens is that the CSG causes POV to be unable to calculate
efficient bounding, and ends up putting the whole thing into one huge
bounding slab. This then means that POV has to test every ray that
crosses this large bounding slab against every one of the 1024
superellipsoids. With efficient bounding, there are 1024 small bounding
slabs and each ray only hits a few of them, so there are only a small
number of superellipsoid intersection tests for each ray.

There are two good solutions. That described by Slime (difference the
hole from every superellipsoid) and the use of a single isosurface (as
described in my previous response).

Slime's method works by allowing POV to create a bounding for each
superellipsoid-minus-big-hole object.

The isosurface method works by the fact that it is a single object, so
each ray only needs one intersection test even when the isosurface looks
like it consists of 1024 smaller pieces.

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

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