POV-Ray : Newsgroups : povray.binaries.images : Seraglio (WIP) : Re: Seraglio (WIP) Server Time
5 Jul 2024 07:11:22 EDT (-0400)
  Re: Seraglio (WIP)  
From: Alain
Date: 30 Aug 2015 13:37:47
Message: <55e33f6b$1@news.povray.org>
Le 15-08-29 17:15, Jérôme M. Berger a écrit :
> On 08/29/2015 06:35 PM, And wrote:
>> And the third is the 100x100 tilings, takes 2 minutes and 4 seconds to render.
>> Every object in it is intersection with the bounding cylinder first, then union.
>>
>>
>> #declare one_piece =
>> union{
>>      box{
>>      <0.005, 0.005, 0>, <0.395, 0.395, 0.01>
>>      }
>>      cylinder{
>>      <0.02, 0, 0>, <0.38, 0, 0>, 1
>>      scale <1,0.18,0.02>
>>      translate <0, 0.2, 0.01>
>>      }
>>      pigment{
>>      rgb<0.4,0.6,0.6>
>>      }
>> }
>>
>> #declare the_tiling =
>> union{
>>      #for(i, 0, 99)
>>          #for(j, 0, 99)
>>              intersection{
>>                  object{
>>                  one_piece
>>                  translate <i*0.4, j*0.4, 0>
>>                  }
>>                  cylinder{
>>                  <20,20,0>,<20,20,1>,19
>>                  }
> Try to add these lines here:
>      bounded_by { box { min_extent (one_piece)+<i*0.4, j*0.4, 0>,
>                         max_extent (one_piece)+<i*0.4, j*0.4, 0> } }
>>                  cutaway_textures
>>              }
>>          #end
>>      #end
>> }
>>
>>
>> the_tiling
>>
>
>

Ouch!
When you add a manual bounding to an union, that union is no longer 
splitted. That cause it to take MUCH more time to render as each ray 
that hit the manual bounding box now need to be tested against each and 
every components of the union. It's similar in effect to uselessly using 
merge instead of union.

Also, as your manual bounding box is larger than the original union, 
it's even slower.


Post a reply to this message

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