From f84e1814e1fe0e216eecd7bfe98a422e4144ee56 Mon Sep 17 00:00:00 2001 From: tomsmeding Date: Wed, 5 Apr 2017 22:59:06 +0200 Subject: Render mandelbrots --- attract.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/attract.c b/attract.c index 7a31bb9..9e093ec 100644 --- a/attract.c +++ b/attract.c @@ -17,11 +17,12 @@ const int MAXITER=200; const double EPS=1e-1; -static double complex att_func(double complex x,double exponent){ - return clog((1-cpow(x,exponent+1))/(1-x)); +static double complex att_func(double complex x,double exponent,double complex start){ + // return clog((1-cpow(x,exponent+1))/(1-x)); // return x; - return x*x+CMPLX(-0.2,0.7); + // return x*x+CMPLX(-0.2,0.7); + return x*x+start; // return csqrt(M_SQRT2*x); // sqrt(2) and 0 // return csqrt(1+x); // phi @@ -100,7 +101,7 @@ static void* thread_entry(void *arg_vp){ cfg.midy-(double)(iy-cfg.height/2)/cfg.unitsz); double complex z=start; for(int i=0;i