Browse Source

adjust colors

Gregg Tavares 6 years ago
parent
commit
41f95de324

+ 1 - 1
threejs/lessons/threejs-optimize-lots-of-objects.md

@@ -473,7 +473,7 @@ data.forEach((row, latNdx) => {
 +    // compute a color
 +    const hue = THREE.Math.lerp(0.7, 0.3, amount);
 +    const saturation = 1;
-+    const lightness = THREE.Math.lerp(0.1, 1.0, amount);
++    const lightness = THREE.Math.lerp(0.4, 1.0, amount);
 +    color.setHSL(hue, saturation, lightness);
 +    // get the colors as an array of values from 0 to 255
 +    const rgb = color.toArray().map(v => v * 255);

+ 1 - 1
threejs/threejs-lots-of-objects-merged-vertexcolors.html

@@ -142,7 +142,7 @@ function main() {
         // compute a color
         const hue = THREE.Math.lerp(0.7, 0.3, amount);
         const saturation = 1;
-        const lightness = THREE.Math.lerp(0.1, 1.0, amount);
+        const lightness = THREE.Math.lerp(0.4, 1.0, amount);
         color.setHSL(hue, saturation, lightness);
         // get the colors as an array of values from 0 to 255
         const rgb = color.toArray().map(v => v * 255);