A small exploration of the creation of color palettes procedurally.

This article on color palettes from IQ details a way to cycle through a color palette using 3 vectors and a variable component.  The example code is in GLSL.

Using the above formula, you can create palettes of your own using this cosine gradient generator.

This project is a small experiment to replicate the function in Ruby, using the DragonRuby Game Toolkit to display the results.

Press "P" to reset the screen and cycle to a different hard-coded palette.

src code : https://gist.github.com/owenbutler/71f33c665115e84f0374e5d5d7204190