Home | History | Annotate | Download | only in utils

Lines Matching refs:endpoints

224     // 4. 8-bit endpoints:
420 static inline void decode_rgba_direct(const int *v, SkColor *endpoints, bool isRGB) {
433 endpoints[0] = SkColorSetARGB(v6, v[0], v[2], v[4]);
434 endpoints[1] = SkColorSetARGB(v7, v[1], v[3], v[5]);
436 endpoints[0] = blue_contract(v7, v[1], v[3], v[5]);
437 endpoints[1] = blue_contract(v6, v[0], v[2], v[4]);
447 static inline void decode_rgba_basescale(const int *v, SkColor *endpoints, bool isRGB) {
456 endpoints[0] = SkColorSetARGB(v4,
460 endpoints[1] = SkColorSetARGB(v5, v[0], v[1], v[2]);
471 static inline void decode_rgba_baseoffset(const int *v, SkColor *endpoints, bool isRGB) {
512 endpoints[0] = SkColorSetARGB(clamp_byte(c[0][0]),
517 endpoints[1] = SkColorSetARGB(clamp_byte(c[1][0]),
1014 // Returns an interpolated color between the two endpoints based on the weight.
1015 static SkColor interpolate_endpoints(const SkColor endpoints[2], int weight) {
1017 interpolate_channel(SkColorGetA(endpoints[0]), SkColorGetA(endpoints[1]), weight),
1018 interpolate_channel(SkColorGetR(endpoints[0]), SkColorGetR(endpoints[1]), weight),
1019 interpolate_channel(SkColorGetG(endpoints[0]), SkColorGetG(endpoints[1]), weight),
1020 interpolate_channel(SkColorGetB(endpoints[0]), SkColorGetB(endpoints[1]), weight));
1023 // Returns an interpolated color between the two endpoints based on the weight.
1032 const SkColor endpoints[2], int weight0, int weight1, int plane) {
1033 int a = interpolate_channel(SkColorGetA(endpoints[0]), SkColorGetA(endpoints[1]), weight0);
1034 int r = interpolate_channel(SkColorGetR(endpoints[0]), SkColorGetR(endpoints[1]), weight0);
1035 int g = interpolate_channel(SkColorGetG(endpoints[0]), SkColorGetG(endpoints[1]), weight0);
1036 int b = interpolate_channel(SkColorGetB(endpoints[0]), SkColorGetB(endpoints[1]), weight0);
1042 SkColorGetR(endpoints[0]), SkColorGetR(endpoints[1]), weight1);
1047 SkColorGetG(endpoints[0]), SkColorGetG(endpoints[1]), weight1);
1052 SkColorGetB(endpoints[0]), SkColorGetB(endpoints[1]), weight1);
1057 SkColorGetA(endpoints[0]), SkColorGetA(endpoints[1]), weight1);
1231 // Converts the sequence of color values into endpoints. The algorithm here
1233 void colorEndpoints(SkColor endpoints[4][2], const int* colorValues) const {
1238 endpoints[i][0] = SkColorSetARGB(0xFF, v[0], v[0], v[0]);
1239 endpoints[i][1] = SkColorSetARGB(0xFF, v[1], v[1], v[1]);
1250 endpoints[i][0] = SkColorSetARGB(0xFF, L0, L0, L0);
1251 endpoints[i][1] = SkColorSetARGB(0xFF, L1, L1, L1);
1260 endpoints[i][0] = SkColorSetARGB(v[2], v[0], v[0], v[0]);
1261 endpoints[i][1] = SkColorSetARGB(v[3], v[1], v[1], v[1]);
1276 endpoints[i][0] = SkColorSetARGB(v2, v0, v0, v0);
1277 endpoints[i][1] = SkColorSetARGB(
1288 decode_rgba_basescale(colorValues, endpoints[i], true);
1294 decode_rgba_direct(colorValues, endpoints[i], true);
1300 decode_rgba_baseoffset(colorValues, endpoints[i], true);
1306 decode_rgba_basescale(colorValues, endpoints[i], false);
1312 decode_rgba_direct(colorValues, endpoints[i], false);
1318 decode_rgba_baseoffset(colorValues, endpoints[i], false);
1595 // endpoints and weights.
1596 SkColor getTexel(const SkColor endpoints[4][2],
1607 endpoints[part], weights[0][x][y], weights[1][x][y], fDualPlane);
1609 result = interpolate_endpoints(endpoints[part], weights[0][x][y]);
1679 // CEM data and the endpoints for each partition share the same CEM.
1959 // Decode the color endpoints
1983 // Decode the colors into the appropriate endpoints.
1984 SkColor endpoints[4][2];
1985 data.colorEndpoints(endpoints, colorValues);
1998 colorPtr[x] = data.getTexel(endpoints, texelWeights, x, y);