Index: src/gpu/GrPictureUtils.cpp |
=================================================================== |
--- src/gpu/GrPictureUtils.cpp (revision 14079) |
+++ src/gpu/GrPictureUtils.cpp (working copy) |
@@ -110,7 +110,8 @@ |
const SkPaint& paint) SK_OVERRIDE { |
} |
virtual void drawDevice(const SkDraw& draw, SkBaseDevice* deviceIn, int x, int y, |
- const SkPaint&) SK_OVERRIDE { |
+ const SkPaint& paint) SK_OVERRIDE { |
+ // deviceIn is the one that is being "restored" back to its parent |
GrGatherDevice* device = static_cast<GrGatherDevice*>(deviceIn); |
if (device->fAlreadyDrawn) { |
@@ -118,6 +119,10 @@ |
} |
device->fInfo.fRestoreOpID = fPicture->EXPERIMENTAL_curOpID(); |
+ device->fInfo.fOrigin = device->getOrigin(); |
+ // TODO: this has to be a deep copy (until the world is immutable) |
+ device->fInfo.fPaint = SkNEW_ARGS(SkPaint, (paint)); |
+ |
fAccelData->addSaveLayerInfo(device->fInfo); |
device->fAlreadyDrawn = true; |
} |