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

Unified Diff: gm/checkerboard.h

Issue 834303005: Factor out checkerboard function in gm and sampleapp into tools. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: ignore pdf gm change Created 5 years, 11 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
Index: gm/checkerboard.h
diff --git a/gm/checkerboard.h b/gm/checkerboard.h
new file mode 100644
index 0000000000000000000000000000000000000000..b2e8faffbf629254ece9ff7220919b1a93b2f144
--- /dev/null
+++ b/gm/checkerboard.h
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2015 Google Inc.
djsollen 2015/01/07 16:24:20 move to tools and make the checkerboard changes in
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+#ifndef checkerboard_DEFINED
+#define checkerboard_DEFINED
+
+#include "SkColor.h"
+
+class SkCanvas;
+
+namespace skiagm {
+
+/**
+ Draw a checkerboard pattern in the current canvas, restricted to
+ the current clip.
+ */
+void Checkerboard(SkCanvas* canvas, SkColor color1, SkColor color2);
+
+inline void Checkerboard(SkCanvas* canvas) {
+ Checkerboard(canvas, 0xFF999999, 0xFF666666);
+}
+
+} // namespace skiagm
+
+#endif // checkerboard_DEFINED
« no previous file with comments | « expectations/gm/Test-Ubuntu12-ShuttleA-GTX660-x86_64-Release/expected-results.json ('k') | gm/checkerboard.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698