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

Unified Diff: tests/PictureTest.cpp

Issue 540963002: Change SkPicture::draw to playback (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Fix nanomsg Created 6 years, 3 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 | « tests/PathOpsSkpClipTest.cpp ('k') | tests/SerializationTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/PictureTest.cpp
diff --git a/tests/PictureTest.cpp b/tests/PictureTest.cpp
index 8b19df21616f3fcf5ab60a045382ec8c6e0dea0e..eb85c94a69fccd0c1911339d598f111bbef040c8 100644
--- a/tests/PictureTest.cpp
+++ b/tests/PictureTest.cpp
@@ -1191,7 +1191,7 @@ void check_save_state(skiatest::Reporter* reporter, SkPicture* picture,
SaveCountingCanvas canvas(SkScalarCeilToInt(picture->cullRect().width()),
SkScalarCeilToInt(picture->cullRect().height()));
- picture->draw(&canvas);
+ picture->playback(&canvas);
REPORTER_ASSERT(reporter, numSaves == canvas.getSaveCount());
REPORTER_ASSERT(reporter, numSaveLayers == canvas.getSaveLayerCount());
@@ -1693,7 +1693,7 @@ static void test_clip_expansion(skiatest::Reporter* reporter) {
SkAutoTUnref<SkPicture> picture(recorder.endRecording());
ClipCountingCanvas testCanvas(10, 10);
- picture->draw(&testCanvas);
+ picture->playback(&testCanvas);
// Both clips should be present on playback.
REPORTER_ASSERT(reporter, testCanvas.getClipCount() == 2);
@@ -1866,7 +1866,7 @@ DEF_TEST(DontOptimizeSaveLayerDrawDrawRestore, reporter) {
SkBitmap replayBM;
make_bm(&replayBM, 100, 100, SK_ColorBLACK, false);
SkCanvas replayCanvas(replayBM);
- picture->draw(&replayCanvas);
+ picture->playback(&replayCanvas);
replayCanvas.flush();
// With the bug present, at (55, 55) we would get a fully opaque red
@@ -1914,10 +1914,10 @@ DEF_TEST(Picture_SkipBBH, r) {
SkCanvas big(640, 480), small(300, 200);
- picture->draw(&big);
+ picture->playback(&big);
REPORTER_ASSERT(r, bbh.searchCalls == 0);
- picture->draw(&small);
+ picture->playback(&small);
REPORTER_ASSERT(r, bbh.searchCalls == 1);
}
« no previous file with comments | « tests/PathOpsSkpClipTest.cpp ('k') | tests/SerializationTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698