Permalink
Browse files

increasing saturation and luminance variance as the colors progress

  • Loading branch information...
1 parent 1ac1588 commit 8f4d1582826be5c9fcbd895f34bdc2f47c1d08dd @substack committed Jul 10, 2011
Showing with 4 additions and 2 deletions.
  1. +4 −2 index.js
View
@@ -33,8 +33,10 @@ var mr = module.exports = function () {
return mr.fromHSL(
angle,
- 75 + Math.random() * 25 * (1 - 1 / Math.sqrt(num)),
- 25 + Math.random() * 50
+ 100 - Math.min(80, 1 / Math.sqrt(1 + Math.floor(num / 12)))
+ * Math.random(),
+ 50 + Math.min(80, (Math.floor(num / 6) * 20))
+ * (Math.random() - 0.5)
);
};
};

0 comments on commit 8f4d158

Please sign in to comment.