Revert "Revert "Compile all fiddle examples locally""
This reverts commit 37575bf3cad759b4703b2021d3fc80bb8eded60f.
Change-Id: Ia31abbd4906ddeed406f3da1128bc4d4177abf24
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/201603
Reviewed-by: Hal Canary <[email protected]>
Commit-Queue: Hal Canary <[email protected]>
diff --git a/docs/examples/Bitmap_034.cpp b/docs/examples/Bitmap_034.cpp
new file mode 100644
index 0000000..ea7b030
--- /dev/null
+++ b/docs/examples/Bitmap_034.cpp
@@ -0,0 +1,15 @@
+// Copyright 2019 Google LLC.
+// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
+#include "fiddle/examples.h"
+// HASH=3e9126152ff1cc592aef6facbcb5fc96
+REG_FIDDLE(Bitmap_034, 256, 64, false, 4) {
+void draw(SkCanvas* canvas) {
+ canvas->scale(.5f, .5f);
+ SkIRect bounds = source.bounds();
+ for (int x : { 0, bounds.width() } ) {
+ for (int y : { 0, bounds.height() } ) {
+ canvas->drawBitmap(source, x, y);
+ }
+ }
+}
+} // END FIDDLE