Struggling with using HSL colors in ThreeJs. Check out my code:
var exampleColor = new THREE.Color( 0xffffff );
exampleColor.setHSL( getHSLColour(exampleObject) );
var exampleMaterial = new THREE.MeshLambertMaterial ( {color: exampleColor} );
The result of getHSLColour looks like this:
0.06721230158730158, 0.9913555194805196, 0.658271103896104
It appears to match the desired format for ThreeJs. However, when I log exampleColor to the console, it displays as an RGB color with NaN values:
T…E.Color {r: NaN, g: NaN, b: NaN}
What am I missing?