summaryrefslogtreecommitdiffstats
path: root/libs/hwui/DisplayListRenderer.h
diff options
context:
space:
mode:
Diffstat (limited to 'libs/hwui/DisplayListRenderer.h')
-rw-r--r--libs/hwui/DisplayListRenderer.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/libs/hwui/DisplayListRenderer.h b/libs/hwui/DisplayListRenderer.h
index abe8b82..43617e7 100644
--- a/libs/hwui/DisplayListRenderer.h
+++ b/libs/hwui/DisplayListRenderer.h
@@ -656,9 +656,8 @@ private:
if (reject) {
mWriter.writeInt(OP_MAY_BE_SKIPPED_MASK | drawOp);
mWriter.writeInt(0xdeaddead);
- uint32_t* location = reject ?
- mWriter.peek32(mWriter.size() - sizeof(int32_t)) : NULL;
- return location;
+ mBufferSize = mWriter.size();
+ return mWriter.peek32(mBufferSize - sizeof(int32_t));
}
mWriter.writeInt(drawOp);
return NULL;
@@ -666,8 +665,7 @@ private:
inline void addSkip(uint32_t* location) {
if (location) {
- *location = (int32_t) (mWriter.peek32(
- mWriter.size() - sizeof(int32_t)) - location);
+ *location = (int32_t) (mWriter.size() - mBufferSize);
}
}
@@ -822,6 +820,7 @@ private:
Vector<SkMatrix*> mMatrices;
SkWriter32 mWriter;
+ uint32_t mBufferSize;
int mRestoreSaveCount;