Diamond-square algorithm in Dart and rendered in HTML5 Canvas