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

Unified Diff: src/gpu/SkGpuDevice.cpp

Issue 383733002: Split SkPictureReplacementPlayback out of SkPicturePlayback (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Added comment Created 6 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/core/SkPictureReplacementPlayback.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/SkGpuDevice.cpp
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index 0dbc2fbbca1e625bcd6f2b1b5157beb405b64496..870ca4a3f6dee2e97a0d4faf9207cca76dfc8df3 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -30,8 +30,8 @@
#include "SkPathEffect.h"
#include "SkPicture.h"
#include "SkPictureData.h"
-#include "SkPicturePlayback.h"
#include "SkPictureRangePlayback.h"
+#include "SkPictureReplacementPlayback.h"
#include "SkRRect.h"
#include "SkStroke.h"
#include "SkSurface.h"
@@ -1938,7 +1938,7 @@ bool SkGpuDevice::EXPERIMENTAL_drawPicture(SkCanvas* canvas, const SkPicture* pi
}
}
- SkPicturePlayback::PlaybackReplacements replacements;
+ SkPictureReplacementPlayback::PlaybackReplacements replacements;
// Generate the layer and/or ensure it is locked
for (int i = 0; i < gpuData->numSaveLayers(); ++i) {
@@ -1947,7 +1947,7 @@ bool SkGpuDevice::EXPERIMENTAL_drawPicture(SkCanvas* canvas, const SkPicture* pi
const GPUAccelData::SaveLayerInfo& info = gpuData->saveLayerInfo(i);
- SkPicturePlayback::PlaybackReplacements::ReplacementInfo* layerInfo =
+ SkPictureReplacementPlayback::PlaybackReplacements::ReplacementInfo* layerInfo =
replacements.push();
layerInfo->fStart = info.fSaveLayerOpID;
layerInfo->fStop = info.fRestoreOpID;
@@ -2030,9 +2030,8 @@ bool SkGpuDevice::EXPERIMENTAL_drawPicture(SkCanvas* canvas, const SkPicture* pi
}
// Playback using new layers
- SkPicturePlayback playback(picture);
+ SkPictureReplacementPlayback playback(picture, &replacements, ops.get());
- playback.setReplacements(&replacements);
playback.draw(canvas, NULL);
// unlock the layers
« no previous file with comments | « src/core/SkPictureReplacementPlayback.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698