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

Unified Diff: tests/CanvasTest.cpp

Issue 2120333002: deferred canvas (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: override drawTextRSXform Created 4 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 | « src/utils/SkDeferredCanvas.cpp ('k') | tools/DumpRecord.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/CanvasTest.cpp
diff --git a/tests/CanvasTest.cpp b/tests/CanvasTest.cpp
index 70c2c04ffabf511239239fe8fe3cf91ab78582af..82e065f5ac783c28d4e2f2d8fe3c3f83744005f6 100644
--- a/tests/CanvasTest.cpp
+++ b/tests/CanvasTest.cpp
@@ -813,3 +813,25 @@ DEF_TEST(PaintFilterCanvas_ConsistentState, reporter) {
REPORTER_ASSERT(reporter, canvas.getClipBounds(&clip1) == filterCanvas.getClipBounds(&clip2));
REPORTER_ASSERT(reporter, clip1 == clip2);
}
+
+///////////////////////////////////////////////////////////////////////////////////////////////////
+
+#include "SkDeferredCanvas.h"
+#include "SkDumpCanvas.h"
+
+DEF_TEST(DeferredCanvas, r) {
+ SkDebugfDumper dumper;
+ SkDumpCanvas dumpC(&dumper);
+
+ SkDeferredCanvas canvas(&dumpC);
+
+ SkPaint paint;
+// paint.setShader(SkShader::MakeColorShader(SK_ColorRED));
+
+ canvas.save();
+ canvas.clipRect(SkRect::MakeWH(55, 55));
+ canvas.translate(10, 20);
+ canvas.drawRect(SkRect::MakeWH(50, 50), paint);
+ canvas.restore();
+}
+
« no previous file with comments | « src/utils/SkDeferredCanvas.cpp ('k') | tools/DumpRecord.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698