

  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-6227584-29']);
  _gaq.push(['_setDomainName', '.2600.nl']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();

window.onload = function()
{
    canvas = document.getElementById("radial");
    context = canvas.getContext("2d");
    canvas.width = document.width;
    canvas.height = document.height;
    x = Math.floor(canvas.width / 2);
    y = Math.floor(canvas.height / 2);
    l = Math.sqrt((Math.pow(x, 2) + Math.pow(y, 2)));
    r = Math.random() * Math.PI*2;
    context.translate(x,y);

    if(window.go !== undefined)
    {
        clearTimeout(window.go);
    }

    draw();
};

function draw()
{
    var g = Math.round(Math.random() * 255);
    context.strokeStyle = "rgba(0, " + g + ", 0, 0.25)";
    var d2 = Math.pow(2, Math.round(Math.random() * 8));
    r = Math.random() * Math.PI*2;
    context.rotate(r);
    context.beginPath();
    context.moveTo(0,0);
    context.lineTo(l,0);
    context.stroke();
    context.closePath();
    window.go = setTimeout(draw, 48);
}

window.onresize = function()
{
    canvas.width = document.width;
    canvas.height = document.height;
    x = Math.floor(canvas.width / 2);
    y = Math.floor(canvas.height / 2);
    l = Math.sqrt((Math.pow(x, 2) + Math.pow(y, 2)));
    r = Math.random() * Math.PI*2;
    context.translate(x,y);
}


