MCPcopy Index your code
hub / github.com/CreateJS/TweenJS / hue2rgb

Function hue2rgb

src/tweenjs/plugins/ColorPlugin.js:251–259  ·  view source on GitHub ↗
(p, q, t)

Source from the content-addressed store, hash-verified

249 }
250
251 function hue2rgb(p, q, t) {
252 if (t < 0) { t += 1; }
253 else if (t > 1) { t -= 1; }
254
255 if (t < 1 / 6) { return p + (q - p) * 6 * t; }
256 if (t < 0.5) { return q; }
257 if (t < 2 / 3) { return p + (q - p) * (2 / 3 - t) * 6; }
258 return p;
259 }
260
261 createjs.ColorPlugin = s;
262}());

Callers 1

hslToRgbFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected