don't adapt any gray colors to 565
Adapting gray to 565 will add a noticeable purple/green tint.
I'd rather only the 565 images in Gold were tainted with that.
Change-Id: Ib09e92b2f78c6de086345124e9eefeb31bbb5fa8
Reviewed-on: https://skia-review.googlesource.com/147422
Commit-Queue: Mike Klein <mtklein@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
diff --git a/gm/textblobcolortrans.cpp b/gm/textblobcolortrans.cpp
index 1362023..cba50a3 100644
--- a/gm/textblobcolortrans.cpp
+++ b/gm/textblobcolortrans.cpp
@@ -62,7 +62,7 @@
void onDraw(SkCanvas* canvas) override {
- canvas->drawColor(sk_tool_utils::color_to_565(SK_ColorGRAY));
+ canvas->drawColor(SK_ColorGRAY);
SkPaint paint;
canvas->translate(10, 40);
@@ -72,8 +72,7 @@
// Colors were chosen to map to pairs of canonical colors. The GPU Backend will cache A8
// Texture Blobs based on the canonical color they map to. Canonical colors are used to
// create masks. For A8 there are 8 of them.
- SkColor colors[] = {SK_ColorCYAN, sk_tool_utils::color_to_565(SK_ColorLTGRAY),
- SK_ColorYELLOW, SK_ColorWHITE};
+ SkColor colors[] = {SK_ColorCYAN, SK_ColorLTGRAY, SK_ColorYELLOW, SK_ColorWHITE};
size_t count = SK_ARRAY_COUNT(colors);
size_t colorIndex = 0;