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

Unified Diff: dm/DMTileGridTask.cpp

Issue 214953003: split SkPictureRecorder out of SkPicture (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: update to ToT (again) Created 6 years, 8 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: dm/DMTileGridTask.cpp
===================================================================
--- dm/DMTileGridTask.cpp (revision 14159)
+++ dm/DMTileGridTask.cpp (working copy)
@@ -29,9 +29,10 @@
SkISize::Make(0,0), // Overlap between adjacent tiles.
SkIPoint::Make(0,0), // Offset.
};
- const SkISize size = fGM->getISize();
- SkTileGridPicture recorded(size.width(), size.height(), info);
- RecordPicture(fGM.get(), &recorded, SkPicture::kUsePathBoundsForClip_RecordingFlag);
+ SkAutoTUnref<SkPictureFactory> factory(SkNEW_ARGS(SkTileGridPictureFactory, (info)));
+ SkAutoTUnref<SkPicture> recorded(RecordPicture(fGM.get(),
+ SkPicture::kUsePathBoundsForClip_RecordingFlag,
+ factory));
SkBitmap full;
SetupBitmap(fReference.colorType(), fGM.get(), &full);
@@ -55,7 +56,7 @@
matrix.postTranslate(-xOffset, -yOffset);
tileCanvas.setMatrix(matrix);
- recorded.draw(&tileCanvas);
+ recorded->draw(&tileCanvas);
tileCanvas.flush();
fullCanvas.drawBitmap(tile, xOffset, yOffset, &paint);
}
« no previous file with comments | « dm/DMSerializeTask.cpp ('k') | dm/DMUtil.h » ('j') | samplecode/SampleTiling.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698