Sunday, January 24, 2010

Realtime fractal raytracing

Hi! I'm back with another video showing a couple of new features.
- Dynamic lighting, now you can adjust the lighting manually as you can see in the video. The shadows are raytraced too so they adjust in realtime.

- Now there's a parameter to set the power (n) of the formula z->z^n+c so you can get different versions of the fractal as showed in the video.

- Frame rate is vastly improved, now all the work is passed to the GPU, including the render plane and ray direction computations.


Some tech data:
- The lighting is a mix of a simple lambert model with a orbit trap that simulates occlusion. Although it's not real occlusion or global illumination, seems to work ok.

- The normal of the surface is computed by central differences.

- The Raymarching is still basically brute force. But with a first step to compute the intersection with a sphere surrounding the fractal.

I'm thinking about putting this tool available for download. I'll add a couple of things and probably next week you can download it from this blog. Hope you like it!! :)

2 comments:

Saquedon said...

Cool dude, can't wait, please if you can also put in a function to render nonrealtime images and videos.

David Jaraiz said...

Hola Tony, cuanto tiempo he¡
espero que todo os vaya bien a ti y a Olga por Weta, y que sepas que voy diciendo por todo sitio que conozco a Tony, que a currao en Avatar, que grande¡
un abrazo y un saludo a Olga.