From 03758163f38aeb0e176e6ac6f4fcfbbff37ee8a1 Mon Sep 17 00:00:00 2001 From: joachimschmidt557 Date: Sun, 24 Feb 2019 14:20:07 +0100 Subject: [PATCH] Initial file --- mandelbrot.nim | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 mandelbrot.nim diff --git a/mandelbrot.nim b/mandelbrot.nim new file mode 100644 index 0000000..d8866f2 --- /dev/null +++ b/mandelbrot.nim @@ -0,0 +1,8 @@ +import complex, colors + + +proc getComplexValueForPixel(x:int, y:int, height:int, width:int, zoom:float): Complex = + (re: (x-width/2.0)/zoom, im: (y-height/2.0)/zoom) + +proc colorMap(i:int, nMax:int): Color = + rgb(0, 0, 0)