diff options
author | 2013-02-06 16:51:04 -0800 | |
---|---|---|
committer | 2013-02-07 12:11:22 -0800 | |
commit | 3bbacf27c0be1bae4e4483577fc89ae3113abe5d (patch) | |
tree | 102ffa5362c1782af27f2f0abad3e9f481479e79 /libs/hwui/OpenGLRenderer.h | |
parent | c2a972131f1870042eb63847d4b24fbe718d8e3f (diff) |
Add a RenderBuffer object to store stencil buffers.
Bug #7146141
This change is needed to add a render buffer cache to avoid
creating and destroying stencil buffers on every frame.
This change also allows the renderer to use a 1 bit or 4 bit
stencil buffer whenever possible.
Finally this change fixes a bug introduced by a previous CL
which causes the stencil buffer to not be updated in certain
conditions. The fix relies on a new optional parameter in
drawColorRects() that can be used to avoid performing a
quickReject on rectangles generated by the clip region.
Change-Id: I2f55a8e807009887b276a83cde9f53fd5c01199f
Diffstat (limited to 'libs/hwui/OpenGLRenderer.h')
-rw-r--r-- | libs/hwui/OpenGLRenderer.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libs/hwui/OpenGLRenderer.h b/libs/hwui/OpenGLRenderer.h index 750b3d245bce..81af7b7b888b 100644 --- a/libs/hwui/OpenGLRenderer.h +++ b/libs/hwui/OpenGLRenderer.h @@ -566,9 +566,11 @@ private: * @param mode The Skia xfermode to use * @param ignoreTransform True if the current transform should be ignored * @param dirty True if calling this method should dirty the current layer + * @param clip True if the rects should be clipped, false otherwise */ status_t drawColorRects(const float* rects, int count, int color, - SkXfermode::Mode mode, bool ignoreTransform = false, bool dirty = true); + SkXfermode::Mode mode, bool ignoreTransform = false, + bool dirty = true, bool clip = true); /** * Draws the shape represented by the specified path texture. @@ -881,6 +883,7 @@ private: // Various caches Caches& mCaches; + Extensions& mExtensions; // List of rectangles to clear after saveLayer() is invoked Vector<Rect*> mLayers; |