StarterCode/static/js/app.js
/**
 * converts the hsv to rgb
 * @param {number} h color hue number from 0-1 as a decimal in place of degrees
 * @param {number} s color saturation from 0-1 as a decimal
 * @param {number} v color value (lightness to darkness) number from 0-1 as a decimal 
 * @returns 
 */
converts the hsv to rgb
@param {number} h color hue number from 0-1 as a decimal in place of degrees
@param {number} s color saturation from 0-1 as a decimal
@param {number} v color value (lightness to darkness) number from 0-1 as a decimal
@returns
converts the hsv to rgb @param { number } h color hue number from 0 - 1 as a decimal in place of degrees @param { number } s color saturation from 0 - 1 as a decimal @param { number } v color value ( lightness to darkness ) number from 0 - 1 as a decimal @returns
function HSVtoRGB(h, s, v) {
	var r, g, b, i, f, p, q, t;
	if (arguments.length === 1) {
		s = h.s, v = h.v, h = h.h;
	}
	i = Math.floor(h * 6);
	f = h * 6 - i;
	p = v * (1 - s);
	q = v * (1 - f * s);
	t = v * (1 - (1 - f) * s);
	switch (i % 6) {
		case 0: r = v, g = t, b = p; break;
		case 1: r = q, g = v, b = p; break;
		case 2: r = p, g = v, b = t; break;
		case 3: r = p, g = q, b = v; break;
		case 4: r = t, g = p, b = v; break;
		case 5: r = v, g = p, b = q; break;
	}
	return {
		r: Math.round(r * 255),
		g: Math.round(g * 255),
		b: Math.round(b * 255)
	};
}
function HSVtoRGB ( h , s , v ) { var r , g , b , i , f , p , q , t ; if ( arguments . length === 1 ) { s = h . s , v = h . v , h = h . h ; } i = Math . floor ( h * 6 ) ; f = h * 6 - i ; p = v * ( 1 - s ) ; q = v * ( 1 - f * s ) ; t = v * ( 1 - ( 1 - f ) * s ) ; switch ( i % 6 ) { case 0 : r = v , g = t , b = p ; break ; case 1 : r = q , g = v , b = p ; break ; case 2 : r = p , g = v , b = t ; break ; case 3 : r = p , g = q , b = v ; break ; case 4 : r = t , g = p , b = v ; break ; case 5 : r = v , g = p , b = q ; break ; } return { r : Math . round ( r * 255 ) , g : Math . round ( g * 255 ) , b : Math . round ( b * 255 ) } ; }
converts the hsv to rgb
 @param {number} h color hue number from 0-1 as a decimal in place of degrees
 @param {number} s color saturation from 0-1 as a decimal
 @param {number} v color value (lightness to darkness) number from 0-1 as a decimal
 @returns
converts the hsv to rgb @param { number } h color hue number from 0 - 1 as a decimal in place of degrees @param { number } s color saturation from 0 - 1 as a decimal @param { number } v color value ( lightness to darkness ) number from 0 - 1 as a decimal @returns