POV-Ray : Newsgroups : povray.general : why are differences soooo slow? : Re: why are differences soooo slow? Server Time
11 Aug 2024 23:19:54 EDT (-0400)
  Re: why are differences soooo slow?  
From: Ken
Date: 26 Apr 1999 22:32:39
Message: <37251300.7854CCD3@pacbell.net>
Rainer Mager wrote:
> 
> Hi all,
> 
>     I may very well answer my own question here but here goes anyway.
> 
>     What are difference CSG operations so darn slow? I had a basic box from
> which I was trying to cust about 200 holes. When I did this the render too
> for ever and the stats showed LOTS of cylinder checks (the holes were made
> with cylinders).
>     I decided to fake it by just placing very thin black cylinders instead
> of holes because in my case the underside of the box was not to be seen and
> since it was dark inside these black cylinders made it look like holes to
> the inside. This rendered very quickly with many fewer cylinder checks.
>     So, my hopothysis is this...on the second case, as soon as the box or
> black cylinder objects are found by a cast ray, the ray is ended and the
> pixel is plotted. In the first case, when a ray enters a hole it must check
> and recheck many times for other objects as it passes through the hole,
> hence the higher stats and the slower render.
> 
>     Is this correct? Is there any way to make the holes and have a
> reasonable render time?
> 
> Thanks,
> 
> --Rainer


  The way the Pov calculates the intersection testing is related
to it's use of internally generated bounding boxes. As you increase
the number of objects in the difference operation the greater the
number of intersecting surface tests the program is required to
perform.
  What I do do cut down on this intersection testing is to manually
bound the difference operation. If you are differencing a 1 unit
cube then add bounding with a 1.1 unit cube at the end of the
difference operation. You should see a noticeable improvement.
  You will also see where pov will issue a warning that you have
unnecessarily used bounding. Ignore this message. It means nothing
in this case. If you used bounding on a two object difference
operation it would be true. Where you have multiple objects in the
difference statement the warning message does not apply.


-- 
Ken Tyler

mailto://tylereng@pacbell.net


Post a reply to this message

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