 |
 |
|
 |
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
Invisible wrote:
> Darren New wrote:
>> http://www.skytopia.com/project/fractal/mandelbulb.html#renders
>
> Any idea how you render something like this?
>
> I mean, I suppose you could use a sphere-tracing algorithm like
> POV-Ray's isosurface{} construct. But is there any better way?
From the site itself:
Any decent 3D software to render the beast?
Not from what I've seen. I originally looked for a 3D program, but
nothing out there seems to render arbitrary functions. Perhaps POVray
comes closest with its isosurface approach, but even then one can't use
local variables or constructs such as While loops.
In the end, I had to create my own renderer (as did the other peeps at
FractalForums.com)
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
Tom Austin wrote:
>> Any idea how you render something like this?
>
>
> From the site itself:
>
> In the end, I had to create my own renderer (as did the other peeps at
> FractalForums.com)
Indeed, my plan is to write a custom renderer. I was more asking about
which kinds of algorithms might be appropriate to use.
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
> Indeed, my plan is to write a custom renderer. I was more asking about
> which kinds of algorithms might be appropriate to use.
AFAIK they are just using a normal backward raytracer like POV, but with
some optimisations to find the fractal surface quickly rather than just
binary search along the ray. You know how when you render a 2D mandelbrot
you can use that double-log formula to get a smooth iteration count? Well I
think they're using a similar formula to get an indicator of how far away
they are from the surface. If you calculate that at 2 or 3 points close
together on your ray, you should be able to extrapolate to get a pretty good
estimate of where the surface actually is. Repeat until you're at
sufficient accuracy.
To estimate the surface normal I think you could re-calculate the fractal
(using the smooth iteration count formula) a short distance away on each
axis. This can then be used for the lighting algorithm or your choice (it
seems a lot of them then shoot a few hundred rays out for some AO lighting
in addition to diffuse and shadows).
It certainly looks exciting, after my df3 isosurface attempts I'm very
tempted to try this myself too. I'm going to think about if a GPU version
is possible.
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
If you really want to render the mandelbulb with povray you either have to
unroll the iterations or you have modify povray itself. I chose the latter.
You can see here how Povray rendered an isosurface using a mandelbulb function.
http://softwareprocess.es/x/x/mandelbulb/1povAA.png
I just added a user function in fnintern.cpp. You can do this too or you can use
my patch found at:
http://softwareprocess.us/index.cgi/Mandelbulb
The patch itself: http://softwareprocess.es/x/x/mandelbulb/fnintern.cpp.patch
abram
"scott" <sco### [at] scott com> wrote:
> > Indeed, my plan is to write a custom renderer. I was more asking about
> > which kinds of algorithms might be appropriate to use.
>
> AFAIK they are just using a normal backward raytracer like POV, but with
> some optimisations to find the fractal surface quickly rather than just
> binary search along the ray. You know how when you render a 2D mandelbrot
> you can use that double-log formula to get a smooth iteration count? Well I
> think they're using a similar formula to get an indicator of how far away
> they are from the surface. If you calculate that at 2 or 3 points close
> together on your ray, you should be able to extrapolate to get a pretty good
> estimate of where the surface actually is. Repeat until you're at
> sufficient accuracy.
>
> To estimate the surface normal I think you could re-calculate the fractal
> (using the smooth iteration count formula) a short distance away on each
> axis. This can then be used for the lighting algorithm or your choice (it
> seems a lot of them then shoot a few hundred rays out for some AO lighting
> in addition to diffuse and shadows).
>
> It certainly looks exciting, after my df3 isosurface attempts I'm very
> tempted to try this myself too. I'm going to think about if a GPU version
> is possible.
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
abram wrote:
> If you really want to render the mandelbulb with povray you either have to
> unroll the iterations or you have modify povray itself. I chose the
> latter.
>
> You can see here how Povray rendered an isosurface using a mandelbulb
> function. http://softwareprocess.es/x/x/mandelbulb/1povAA.png
>
> I just added a user function in fnintern.cpp. You can do this too or you
> can use my patch found at:
> http://softwareprocess.us/index.cgi/Mandelbulb
>
> The patch itself:
> http://softwareprocess.es/x/x/mandelbulb/fnintern.cpp.patch
That's awesome!
"Later I considered that if you were only going to do so many iterations
that povray's own internal language would've sufficed as it'd just be loop
unrolling."
Heh, I don't think so... It would have been a few orders of magnitude
slower. How long did your two renders take?
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
Nicolas Alvarez <nic### [at] gmail com> wrote:
> "Later I considered that if you were only going to do so many iterations
> that povray's own internal language would've sufficed as it'd just be loop
> unrolling."
>
> Heh, I don't think so... It would have been a few orders of magnitude
> slower. How long did your two renders take?
27 minutes for 1920x1200 with nothing on (no AA, etc.).
27 hours for 1920x1200 with everything I could turn on at the command line
(radiosity and antialiasing).
The scenes are garbage, I just had to see the Mandelbulb. I'm hoping that
someone with some taste picks up this patch and produces something nice.
abram
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |
|  |
|
 |
Nicolas Alvarez schrieb:
> "Later I considered that if you were only going to do so many iterations
> that povray's own internal language would've sufficed as it'd just be loop
> unrolling."
>
> Heh, I don't think so... It would have been a few orders of magnitude
> slower.
Not really. more like a factor of 4 or so, from my experience. Enough to
want the POV-Ray internal function, but not enough to be unable to live
without.
Post a reply to this message
|
 |
|  |
|  |
|
 |
|
 |
|  |