(H, S, options)
| 175 | } |
| 176 | |
| 177 | function pickBrightness(H, S, options) { |
| 178 | var bMin = getMinimumBrightness(H, S), |
| 179 | bMax = 100; |
| 180 | |
| 181 | switch (options.luminosity) { |
| 182 | case "dark": |
| 183 | bMax = bMin + 20; |
| 184 | break; |
| 185 | |
| 186 | case "light": |
| 187 | bMin = (bMax + bMin) / 2; |
| 188 | break; |
| 189 | |
| 190 | case "random": |
| 191 | bMin = 0; |
| 192 | bMax = 100; |
| 193 | break; |
| 194 | } |
| 195 | |
| 196 | return randomWithin([bMin, bMax]); |
| 197 | } |
| 198 | |
| 199 | function setFormat(hsv, options) { |
| 200 | switch (options.format) { |
no test coverage detected
searching dependent graphs…