@@ -0,0 +1,1357 @@
+from __future__ import division%0A%0Aimport numpy as np%0Afrom skimage.color import hsv2rgb%0Afrom skimage.io import imsave%0A%0Aimport celiagg as agg%0A%0ASIZE = 1000%0ACOUNT = 50%0ALEVELS = 35%0A%0Acanvas = agg.CanvasRGB24(np.zeros((SIZE, SIZE, 3), dtype=np.uint8))%0Ags = agg.GraphicsState(drawing_mode=agg.DrawingMode.DrawFill)%0Atransform = agg.Transform()%0A%0Acanvas.clear(1, 1, 1)%0Acircle = agg.Path()%0Acircle.ellipse(0, 0, 50, 50)%0A%0Ats = np.linspace(0, 2*np.pi, COUNT, endpoint=False)%0Acenters = np.stack((np.cos(ts), np.sin(ts)), axis=1)%0A%0Agray = agg.SolidPaint(0.5, 0.5, 0.5)%0Ahsvs = np.ones((LEVELS, 1, 3))%0Ahsvs%5B:, 0, 0%5D = np.linspace(0, 1, LEVELS, endpoint=False)%0Ahsvs%5B:, 0, 1%5D *= 0.95  # Saturation%0Ahsvs%5B:, 0, 2%5D *= 0.85  # Value%0Argbs = hsv2rgb(hsvs).reshape(LEVELS, 3)%0A%0Aoffset = 10%0Afor d in range(LEVELS):%0A    radius = 2*np.pi*offset / (COUNT*2)%0A    scale = radius / 50%0A    colors = (gray, agg.SolidPaint(*rgbs%5Bd%5D))%0A%0A    for i in range(COUNT):%0A        transform.reset()%0A        transform.translate(SIZE/2 + offset*centers%5Bi, 0%5D,%0A                            SIZE/2 + offset*centers%5Bi, 1%5D)%0A        transform.scale(scale, scale)%0A        canvas.draw_shape(circle, transform, gs, fill=colors%5B(d+i) %25 2%5D)%0A%0A    # Estimate how far to push out the next line%0A    newradius = 2 * np.pi * (offset + radius * 2) / (COUNT*2)%0A    offset += radius + newradius%0A%0Aimsave('spiral.png', canvas.array)%0A

Add an example which draws a spiral (#26)