Commit 1d066087 authored by Michael Niedermayer's avatar Michael Niedermayer

mandelbrot: only check periodicity once for each period instead of twice.

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 2fee131b
...@@ -194,7 +194,7 @@ static void draw_mandelbrot(AVFilterContext *ctx, uint32_t *color, int linesize, ...@@ -194,7 +194,7 @@ static void draw_mandelbrot(AVFilterContext *ctx, uint32_t *color, int linesize,
zi= 2*zr*zi + ci; zi= 2*zr*zi + ci;
zr= t + cr; zr= t + cr;
if(use_zyklus){ if(use_zyklus){
if(i && mb->zyklus[i>>1][0]==zr && mb->zyklus[i>>1][1]==zi) if((i&1) && mb->zyklus[i>>1][0]==zr && mb->zyklus[i>>1][1]==zi)
break; break;
mb->zyklus[i][0]= zr; mb->zyklus[i][0]= zr;
mb->zyklus[i][1]= zi; mb->zyklus[i][1]= zi;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment