Searched refs:fitIndex (Results 1 – 1 of 1) sorted by relevance
/frameworks/base/core/java/com/android/internal/colorextraction/types/ |
D | Tonal.java | 145 int fitIndex = bestFit(palette, hsl[0], hsl[1], hsl[2]); in runTonalExtraction() local 146 if (fitIndex == -1) { in runTonalExtraction() 152 float[] h = fit(palette.h, hsl[0], fitIndex, in runTonalExtraction() 154 float[] s = fit(palette.s, hsl[1], fitIndex, 0.0f, 1.0f); in runTonalExtraction() 155 float[] l = fit(palette.l, hsl[2], fitIndex, 0.0f, 1.0f); in runTonalExtraction() 159 StringBuilder builder = new StringBuilder("Tonal Palette - index: " + fitIndex + in runTonalExtraction() 160 ". Main color: " + Integer.toHexString(getColorInt(fitIndex, h, s, l)) + in runTonalExtraction() 172 int primaryIndex = fitIndex; in runTonalExtraction() 199 } else if (fitIndex < 2) { in runTonalExtraction() 202 primaryIndex = Math.min(fitIndex, 3); in runTonalExtraction() [all …]
|