aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkMultiPictureDraw.cpp
diff options
context:
space:
mode:
authorGravatar robertphillips <robertphillips@google.com>2014-12-03 07:33:57 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2014-12-03 07:33:57 -0800
commite99d499caa7dbc80b58e0faf5ce137e7d30cc5d0 (patch)
tree51fbc4f33ad173c3504998826e6333d99cb67f3f /src/core/SkMultiPictureDraw.cpp
parent2dd1ae016d7f297b433c3ea3a771ef8e01657c1f (diff)
Fuse GrReplacements and GrLayerCache
The conversion step from GrCachedLayer to ReplacementInfo isn't necessary. Review URL: https://codereview.chromium.org/769533004
Diffstat (limited to 'src/core/SkMultiPictureDraw.cpp')
-rw-r--r--src/core/SkMultiPictureDraw.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/core/SkMultiPictureDraw.cpp b/src/core/SkMultiPictureDraw.cpp
index bd1e8fe08c..ed099a02e1 100644
--- a/src/core/SkMultiPictureDraw.cpp
+++ b/src/core/SkMultiPictureDraw.cpp
@@ -15,6 +15,7 @@
#include "SkTaskGroup.h"
#if SK_SUPPORT_GPU
+#include "GrContext.h"
#include "GrLayerHoister.h"
#include "GrRecordReplaceDraw.h"
#include "GrRenderTarget.h"
@@ -168,13 +169,9 @@ void SkMultiPictureDraw::draw() {
GrLayerHoister::DrawLayers(context, needRendering);
- GrReplacements replacements;
-
- GrLayerHoister::ConvertLayersToReplacements(picture, needRendering, &replacements);
- GrLayerHoister::ConvertLayersToReplacements(picture, recycled, &replacements);
-
// Render the entire picture using new layers
- GrRecordReplaceDraw(picture, canvas, &replacements, initialMatrix, NULL);
+ GrRecordReplaceDraw(picture, canvas, context->getLayerCache(),
+ initialMatrix, NULL);
GrLayerHoister::UnlockLayers(context, needRendering);
GrLayerHoister::UnlockLayers(context, recycled);