diff options
author | Chris Craik <ccraik@google.com> | 2015-06-08 16:49:43 -0700 |
---|---|---|
committer | Chris Craik <ccraik@google.com> | 2015-06-12 13:34:58 -0700 |
commit | a766cb2bce5db9108c0266fbebea6aa18d5713ff (patch) | |
tree | 2718003d7dc16d0a5f94aeda1acf40c5eaae8fad /libs/hwui/DisplayListOp.h | |
parent | 4e9d9b2a590105035c29f12ecf0689333e6b55e7 (diff) | |
download | frameworks_base-a766cb2bce5db9108c0266fbebea6aa18d5713ff.zip frameworks_base-a766cb2bce5db9108c0266fbebea6aa18d5713ff.tar.gz frameworks_base-a766cb2bce5db9108c0266fbebea6aa18d5713ff.tar.bz2 |
Put WebViews with on a HW layer if stencil/shader clipping is needed
bug:17322378
Change-Id: I0de574bf116b30e2ad4194366e19d47d49708902
Diffstat (limited to 'libs/hwui/DisplayListOp.h')
-rw-r--r-- | libs/hwui/DisplayListOp.h | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/libs/hwui/DisplayListOp.h b/libs/hwui/DisplayListOp.h index e9d6ebc..fb2852a 100644 --- a/libs/hwui/DisplayListOp.h +++ b/libs/hwui/DisplayListOp.h @@ -1398,9 +1398,10 @@ class DrawRenderNodeOp : public DrawBoundedOp { friend class RenderNode; // grant RenderNode access to info of child friend class DisplayListData; // grant DisplayListData access to info of child public: - DrawRenderNodeOp(RenderNode* renderNode, const mat4& transformFromParent) + DrawRenderNodeOp(RenderNode* renderNode, const mat4& transformFromParent, bool clipIsSimple) : DrawBoundedOp(0, 0, renderNode->getWidth(), renderNode->getHeight(), nullptr) , mRenderNode(renderNode) + , mRecordedWithPotentialStencilClip(!clipIsSimple || !transformFromParent.isSimple()) , mTransformFromParent(transformFromParent) , mSkipInOrderDraw(false) {} @@ -1436,6 +1437,20 @@ public: private: RenderNode* mRenderNode; + /** + * This RenderNode was drawn into a DisplayList with the canvas in a state that will likely + * require rendering with stencil clipping. Either: + * + * 1) A path clip or rotated rect clip was in effect on the canvas at record time + * 2) The RenderNode was recorded with a non-simple canvas transform (e.g. rotation) + * + * Note: even if this is false, non-rect clipping may still be applied applied either due to + * property-driven rotation (either in this RenderNode, or any ancestor), or record time + * clipping in an ancestor. These are handled in RenderNode::prepareTreeImpl since they are + * dynamic (relative to a static DisplayList of a parent), and don't affect this flag. + */ + bool mRecordedWithPotentialStencilClip; + /////////////////////////// // Properties below are used by RenderNode::computeOrderingImpl() and issueOperations() /////////////////////////// |