Welcome to Fractal Forums

Fractal Software => Feature Requests => Topic started by: cKleinhuis on February 14, 2015, 11:51:34 PM




Title: pre-transform in mandelbulber
Post by: cKleinhuis on February 14, 2015, 11:51:34 PM
hi there, i consider a space warp pre transform step as very versatile, similar to the transform method that is common ultrafractal

the definition would be easy as:


vec3 transform(vec3)

this should be stackable (as in ultrafractal ) and each of it shall have its own parameters

to achieve donut like transformations, mirroring or modulus space filling or whatever one comes up with


Title: Re: pre-transform in mandelbulber
Post by: Buddhi on February 15, 2015, 08:13:36 PM
hi there, i consider a space warp pre transform step as very versatile, similar to the transform method that is common ultrafractal

the definition would be easy as:


vec3 transform(vec3)

this should be stackable (as in ultrafractal ) and each of it shall have its own parameters

to achieve donut like transformations, mirroring or modulus space filling or whatever one comes up with

I don't know Ultrafractal. Could you  show me some example (as pseudo-code), how it should work? What this transform() function is doing? Is it translate, scale and rotation together?


Title: Re: pre-transform in mandelbulber
Post by: cKleinhuis on February 15, 2015, 08:20:37 PM
its a standard transformation, in ultrafractal it is called "mapping"

it works as simple as input a vec3 and output a vec3

some examples, because its really easy to do but offers some neat possibilities

identity - does nothing ;)
vec3 transform(input)return input;

modulus - creates copies of the formula
vec3 transform(input)return input%range;

inverse - inverses formula (turns inside out, like inverse mandelbrot)
vec3 transform(input)return 1/input;

... and so on fish eye effects and such are also possible, but with the hard mode for 3d, so, just warp the space before iterating

obviously this method is not directly useable to transform a formula along a torus shape, like aexion described, nevertheless some space transformations as options in the program using the shading language comes in very handy from time to time


Title: Re: pre-transform in mandelbulber
Post by: Buddhi on February 15, 2015, 08:35:20 PM
Thanks for explanation. Some of transforms are already implemented. There is translate, modulo and rotation of whole fractal and each primitive object. Now when there are implemented boolean functions, I'm thinking to implement transform for every formula separately.
There will be also possible to do boolean operations with primitive objects.