Merge "Ignore low chroma colors when calculating a hue's population" into sc-v2-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
0c1eb6a2be
@@ -249,6 +249,9 @@ public class ColorScheme(@ColorInt seed: Int, val darkTheme: Boolean) {
|
||||
val population = populationByColor[entry.key]!!
|
||||
val cam = camByColor[entry.key]!!
|
||||
val hue = cam.hue.roundToInt() % 360
|
||||
if (cam.chroma <= MIN_CHROMA) {
|
||||
continue
|
||||
}
|
||||
huePopulation[hue] = huePopulation[hue] + population
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user