Index: src/gpu/GrLayerCache.cpp |
diff --git a/src/gpu/GrLayerCache.cpp b/src/gpu/GrLayerCache.cpp |
index 0c2e6b0a4daf28585de251bc796320b86f1b55c0..8e61cb761edec788d33953100fb3fcf0d6f1846a 100644 |
--- a/src/gpu/GrLayerCache.cpp |
+++ b/src/gpu/GrLayerCache.cpp |
@@ -119,28 +119,31 @@ void GrLayerCache::freeAll() { |
GrCachedLayer* GrLayerCache::createLayer(uint32_t pictureID, |
int start, int stop, |
+ const SkIPoint& offset, |
const SkMatrix& ctm) { |
SkASSERT(pictureID != SK_InvalidGenID && start > 0 && stop > 0); |
- GrCachedLayer* layer = SkNEW_ARGS(GrCachedLayer, (pictureID, start, stop, ctm)); |
+ GrCachedLayer* layer = SkNEW_ARGS(GrCachedLayer, (pictureID, start, stop, offset, ctm)); |
fLayerHash.add(layer); |
return layer; |
} |
GrCachedLayer* GrLayerCache::findLayer(uint32_t pictureID, |
int start, int stop, |
+ const SkIPoint& offset, |
const SkMatrix& ctm) { |
SkASSERT(pictureID != SK_InvalidGenID && start > 0 && stop > 0); |
- return fLayerHash.find(GrCachedLayer::Key(pictureID, start, stop, ctm)); |
+ return fLayerHash.find(GrCachedLayer::Key(pictureID, start, stop, offset, ctm)); |
} |
GrCachedLayer* GrLayerCache::findLayerOrCreate(uint32_t pictureID, |
int start, int stop, |
+ const SkIPoint& offset, |
const SkMatrix& ctm) { |
SkASSERT(pictureID != SK_InvalidGenID && start > 0 && stop > 0); |
- GrCachedLayer* layer = fLayerHash.find(GrCachedLayer::Key(pictureID, start, stop, ctm)); |
+ GrCachedLayer* layer = fLayerHash.find(GrCachedLayer::Key(pictureID, start, stop, offset, ctm)); |
if (NULL == layer) { |
- layer = this->createLayer(pictureID, start, stop, ctm); |
+ layer = this->createLayer(pictureID, start, stop, offset, ctm); |
} |
return layer; |