Legacy raster still doesn't handle transparent LCD

Bug: skia:6655
Change-Id: I1431fb5bcf955dd32c15dad9d24a6a7a7aa626f0
Reviewed-on: https://skia-review.googlesource.com/17788
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
This commit is contained in:
Brian Osman 2017-05-23 17:09:19 -04:00 committed by Skia Commit-Bot
parent 355feabac2
commit 0610a462ad

View File

@ -146,8 +146,13 @@ DEF_SIMPLE_GM(savelayer_lcdtext, canvas, 620, 260) {
for (auto preserve : gPreserveLCDText) {
preserve ? canvas->saveLayerPreserveLCDTextRequests(nullptr, nullptr)
: canvas->saveLayer(nullptr, nullptr);
canvas->drawString("Hamburgefons", 30, 60, paint);
if (preserve && !canvas->imageInfo().colorSpace()) {
SkPaint noLCD = paint;
noLCD.setLCDRenderText(false);
canvas->drawString("LCD not supported", 30, 60, noLCD);
} else {
canvas->drawString("Hamburgefons", 30, 60, paint);
}
SkPaint p;
p.setColor(0xFFCCCCCC);