aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrLayerHoister.h
diff options
context:
space:
mode:
authorGravatar robertphillips <robertphillips@google.com>2014-09-29 11:39:38 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2014-09-29 11:39:38 -0700
commited42059d2f97d4f8d247af3cbf5dc290c32785eb (patch)
treee30c2284346b6c9f4d7cc4411d85bacd94f16a1d /src/gpu/GrLayerHoister.h
parent92f7fc4868cb02d364c1c1ea990ea81a2aab46b9 (diff)
Move offset and CTM from LayerCache Key to per-hoisted-layer info
This CL reduces the amount of information used in the layer cache key: - the stop value isn't needed since the start value uniquely identifies the layer in the picture. - only the upper-left 2x2 portion of the CTM should be used as a key for looking up cached layers. - individual layers can be redraw in different locations so the final offset cannot be a part of the key. Since this data is no longer stored in the cached layer, but is still required to draw the cached layer, it is now stored in the per-layer information (i.e., HoistedLayer). This is split out of (Fix sub-picture layer rendering bugs - https://codereview.chromium.org/597293002/). BUG=skia:2315 R=egdaniel@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/609403003
Diffstat (limited to 'src/gpu/GrLayerHoister.h')
-rw-r--r--src/gpu/GrLayerHoister.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gpu/GrLayerHoister.h b/src/gpu/GrLayerHoister.h
index acf1901096..6aff2ea32a 100644
--- a/src/gpu/GrLayerHoister.h
+++ b/src/gpu/GrLayerHoister.h
@@ -26,6 +26,8 @@ public:
struct HoistedLayer {
const SkPicture* fPicture;
GrCachedLayer* fLayer;
+ SkIPoint fOffset;
+ SkMatrix fCTM;
};
/** Find the layers in 'topLevelPicture' that need hoisting. Note that the discovered