MCPcopy
hub / github.com/MrNothing/AI-Blocks / hue2rgb

Function hue2rgb

Sources/src/libs/jquery-ui.js:1763–1775  ·  view source on GitHub ↗
( p, q, h )

Source from the content-addressed store, hash-verified

1761// https://code.google.com/p/maashaack/source/browse/packages/graphics/trunk/src/graphics/colors/HUE2RGB.as?r=5021
1762
1763function hue2rgb( p, q, h ) {
1764 h = ( h + 1 ) % 1;
1765 if ( h * 6 < 1 ) {
1766 return p + ( q - p ) * h * 6;
1767 }
1768 if ( h * 2 < 1 ) {
1769 return q;
1770 }
1771 if ( h * 3 < 2 ) {
1772 return p + ( q - p ) * ( ( 2 / 3 ) - h ) * 6;
1773 }
1774 return p;
1775}
1776
1777spaces.hsla.to = function( rgba ) {
1778 if ( rgba[ 0 ] == null || rgba[ 1 ] == null || rgba[ 2 ] == null ) {

Callers 1

jquery-ui.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected