POV-Ray : Newsgroups : povray.windows : SLOOW CSG rendering with large num of complex objects (union or merge) : Re: SLOOW CSG rendering with large num of complex objects (union or merge) Server Time
17 May 2024 03:28:08 EDT (-0400)
  Re: SLOOW CSG rendering with large num of complex objects (union or merge)  
From: Trevor G Quayle
Date: 8 Jan 2008 20:45:01
Message: <web.478426b62ef1916d2ae8612c0@news.povray.org>
"COMPATT" <com### [at] hotmailcom> wrote:
> I have created what may turn into a nice macro which can generate "anatomically
> correct" impact craters for a planet or moon by simply specifying the desired
> diameter of the crater and it's longitude and latitude on the planet's surface.
>  For the most part I am happy with the results but would like to add a few
> enhancements before sharing it with the community. The macro currently handles
> the situation of "older" craters being partially obliterated by later impacts
> and appropriately sized craters will display features such as peak rings and
> central peaks. The per crater parse time is not to bad and is the same
> regardless of how large or small the desired crater is.
>
> My first goal is to reproduce the craters on the moon and I have downloaded and
> database of some 6000 craters to work with.  Obviously, this takes some time to
> parse especially when the macro has to check for and then handle instances of
> crater overlapping. But rendering of the craters as separate objects runs very
> quickly afterwards.
>
> The slowdown (and I mean SLOOOOOOOOOOOOWWWWWWWDDDDDOOOOWWNNNNN!!!!!!!!) Occures
> when I have to merge these craters with the "uncratered" parent planet
> (sphere).
> The floor inside an impact crater is always lower than that of the original
> surface outside of the crater this means I have to remove enough of the
> original sphere's surface where the crater will "sit" so the inside of the
> crater is below the surface it impacts on. Every time I do this by subtracting
> the craters from the planet using a difference CSG, the render time goes from a
> couple of min to literaly days (almost a week). If I just render the planet with
> the needed "excavations" the render takes hours (2 to 3) but that is tolerable
> compared to a week. It is when I try to unite the craters and the "excavated"
> planet that render time becomes downright glacial.  I have tried this with both
> union and merge with no change in the slowness of the render any ideas on how to
> speed this up would be greatly appreciated.

A lot of objects in a CSG can be very slow, espscially if using intersection or
difference.  Perhaps try using blobs as I did for a golf ball some time ago,
which ends up rendering a lot faster.  You can either create the whole planet
as a single blob entity, or just the craters (still create all the craters as a
single blob item though) and union/difference them with the planet.

-tgq

-tgq


Post a reply to this message

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