Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(482)

Unified Diff: gm/displacement.cpp

Issue 1237233004: make colorwheelnative displacement dropshadowimagefilter getposttextpath gm portable (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gm/colorwheel.cpp ('k') | gm/dropshadowimagefilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/displacement.cpp
diff --git a/gm/displacement.cpp b/gm/displacement.cpp
index 7b3d39c797db46da9e7e41b750bfa047689e91d6..129682ddec157f8d367bc2b7ff1aea7790913c5c 100644
--- a/gm/displacement.cpp
+++ b/gm/displacement.cpp
@@ -38,8 +38,8 @@ protected:
canvas.clear(0x00000000);
SkPaint paint;
paint.setAntiAlias(true);
- sk_tool_utils::set_portable_typeface(&paint);
- paint.setColor(0xFF884422);
+ sk_tool_utils::set_portable_typeface_always(&paint);
+ paint.setColor(sk_tool_utils::color_to_565(0xFF884422));
paint.setTextSize(SkIntToScalar(96));
const char* str = "g";
canvas.drawText(str, strlen(str), SkIntToScalar(15), SkIntToScalar(55), paint);
@@ -48,7 +48,8 @@ protected:
void make_checkerboard(SkBitmap* bitmap, int w, int h) {
bitmap->allocN32Pixels(w, h);
SkCanvas canvas(*bitmap);
- sk_tool_utils::draw_checkerboard(&canvas, 0xFF244484, 0xFF804020, 8);
+ sk_tool_utils::draw_checkerboard(&canvas, sk_tool_utils::color_to_565(0xFF244484),
+ sk_tool_utils::color_to_565(0xFF804020), 8);
}
virtual SkISize onISize() {
« no previous file with comments | « gm/colorwheel.cpp ('k') | gm/dropshadowimagefilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698