POV-Ray : Newsgroups : povray.newusers : Re: Simple difference cripples render time Server Time
5 Nov 2024 05:23:10 EST (-0500)
  Re: Simple difference cripples render time (Message 1 to 2 of 2)  
From: Steve
Subject: Re: Simple difference cripples render time
Date: 24 Jul 2002 05:00:44
Message: <slrnajsr4k.m28.steve@zeropps.org.uk>
On Tue, 23 Jul 2002 21:42:05 +0100, Mark Hanford wrote:
> I've got a room made of a union of 4 boxes, out of which I difference a
> door using another box.
> 
> The scene is relatively simple, with some models and lights etc which
> takes about almost exactly one minute to render, however as soon as I
> put in the box for the hole, the time is doubled.  Once I put in a
> window or so the time shoots...  Surely the difference between two boxes
> does not constitute "complex CSG in need of manual bounding"?

You're taking a box away from a union not a box away from a box. 

If you difference the individual box rather than the union then you'll
probably find a much quicker render. 

-- 
#local i=.1;#local I=(i/i)/i;#local l=(i+i)/i;#local ll=(I/i)/l;box{<-ll,
-((I/I)+l),-ll><ll,-l,ll>pigment{checker scale l}finish{ambient((I/l)/I)+
(l/I)}}sphere{<i-i,l-l,(I/l)>l/l pigment{rgb((I/l)/I)}finish{reflection((
I/l)/I)-(l/I)specular(I/l)/I}}light_source{<I-l,I+I,(I-l)/l>l/l} // Steve


Post a reply to this message

From: Robbert
Subject: Re: Simple difference cripples render time
Date: 24 Jul 2002 12:22:57
Message: <3d3ed461@news.povray.org>
I actually hit this with my entry for the dreaming stills.  I had a bunch of
'bubbles' in the back that I wanted to slice off a little bit from them with
a box.  Initially I did the difference of the box with the union of all the
bubbles.  I thought that would have been the most efficient.  Rendered it...
Ack, Erk, Come you can do it!?!  Took for ages.

Just for kicks I redid the difference based on unioned 'rows' of bubbles to
see if that would make a difference.  I expected worse performance but the
end result was more than twice the speed up (subjective).  I didn't try
changing it to a per bubble but I assume it would be even faster.  Something
to keep in mind for future.

I didn't fare too well though, 48th in dreaming!?  Blah!  Ah well.  First
ever entry.

Robbert de Groot

"Steve" <ste### [at] zeroppsuklinuxnet> wrote in message
news:slr### [at] zeroppsorguk...
> On Tue, 23 Jul 2002 21:42:05 +0100, Mark Hanford wrote:
> > I've got a room made of a union of 4 boxes, out of which I difference a
> > door using another box.
> >
> > The scene is relatively simple, with some models and lights etc which
> > takes about almost exactly one minute to render, however as soon as I
> > put in the box for the hole, the time is doubled.  Once I put in a
> > window or so the time shoots...  Surely the difference between two boxes
> > does not constitute "complex CSG in need of manual bounding"?
>
> You're taking a box away from a union not a box away from a box.
>
> If you difference the individual box rather than the union then you'll
> probably find a much quicker render.
>
> --
> #local i=.1;#local I=(i/i)/i;#local l=(i+i)/i;#local ll=(I/i)/l;box{<-ll,
> -((I/I)+l),-ll><ll,-l,ll>pigment{checker scale l}finish{ambient((I/l)/I)+
> (l/I)}}sphere{<i-i,l-l,(I/l)>l/l pigment{rgb((I/l)/I)}finish{reflection((
> I/l)/I)-(l/I)specular(I/l)/I}}light_source{<I-l,I+I,(I-l)/l>l/l} // Steve


Post a reply to this message

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