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

Unified Diff: tests/WritePixelsTest.cpp

Issue 22978012: Split SkDevice into SkBaseDevice and SkBitmapDevice (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Updating to ToT (10994) Created 7 years, 4 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/TileGridTest.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/WritePixelsTest.cpp
===================================================================
--- tests/WritePixelsTest.cpp (revision 10994)
+++ tests/WritePixelsTest.cpp (working copy)
@@ -227,7 +227,7 @@
const SkBitmap& bitmap,
int writeX, int writeY,
SkCanvas::Config8888 config8888) {
- SkDevice* dev = canvas->getDevice();
+ SkBaseDevice* dev = canvas->getDevice();
if (!dev) {
return false;
}
@@ -305,7 +305,7 @@
#endif
};
-SkDevice* createDevice(const CanvasConfig& c, GrContext* grCtx) {
+SkBaseDevice* createDevice(const CanvasConfig& c, GrContext* grCtx) {
switch (c.fDevType) {
case kRaster_DevType: {
SkBitmap bmp;
@@ -320,7 +320,7 @@
SkAutoLockPixels alp(bmp);
memset(bmp.getPixels(), DEV_PAD, bmp.getSafeSize());
}
- return new SkDevice(bmp);
+ return new SkBitmapDevice(bmp);
}
#if SK_SUPPORT_GPU
case kGpu_BottomLeft_DevType:
@@ -435,7 +435,7 @@
}
#endif
- SkAutoTUnref<SkDevice> device(createDevice(gCanvasConfigs[i], context));
+ SkAutoTUnref<SkBaseDevice> device(createDevice(gCanvasConfigs[i], context));
SkCanvas canvas(device);
static const SkCanvas::Config8888 gSrcConfigs[] = {
« no previous file with comments | « tests/TileGridTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698