c++ - rendering of fractal flame images -


i stumbled upon iterated system fractals , got interested in how implement code can render these ifs plots. inspiration comes here

im not quite sure if right thing, , i'm wondering if might able clarify how 1 should intepret algorithm.

what far is: make set f of size n linear transforms in form of constants a_i, b_i, ..., f_i

and set v of size k called 'variations' variation takes point , returns point in 2d.

then each function in f each gets color associated.

then choose random point p , random color c  make histogram h 1 bucket per pixel  repeat many times:    = random int in [0;n-1]   p_new = (0, 0)   c = (c + colorof i'th function) / 2    v in variations:     p_new = p_new + v(a_i * p.x + b_i * p.y + c_i, d_i * p.x + e_i * p.y + f_i)     p = p_new    histogram @ p gets +1   color @ p = c  finally, draw recorded colors 

i images, yet seem quite dull compared see other being capable of producing. examples of have managed create can seen here.

so i'm wondering if plotting correctly.

my first question be: correct choose single affine transformation , accumulate variations?

also, correct associate color functions f, or should use colors functions in v instead?

lastly, i''m wondering how colors should renderd, since images seem pale. article discusses using logarithm determine color.

what have done far keeping track of histogram bucket largets hitcount "maxfreq", , then, when plotting color, multiply color values log(currentffreq) / log(maxfreq). remotely correct?

sorry possibly vauge formulations, , in advance : )


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -