Skip to content

Instantly share code, notes, and snippets.

@nmorse
Created February 27, 2016 00:16
Show Gist options
  • Save nmorse/bbaf941e284fe84bf0ab to your computer and use it in GitHub Desktop.
Save nmorse/bbaf941e284fe84bf0ab to your computer and use it in GitHub Desktop.
import Color exposing (..)
import Graphics.Collage exposing (..)
import Graphics.Element exposing (..)
dots = 50
main : Element
main =
collage 150 150 (List.map shape [0..dots-1])
shape : Int -> Form
shape n =
let
angle = degrees ((30*(12/dots)) * toFloat n)
in
circle (10*(12/dots))
|> filled (hsl angle 0.7 ((0.25 * (sin ((angle)*3)))+0.5))
|> move (45 * cos angle, 45 * sin angle)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment