Lines Matching refs:state
71 virtual void add(DrawOp* op, const DeferredDisplayState* state, bool opaqueOverBounds) { in add() argument
73 mBounds.unionWith(state->mBounds); in add()
75 mOps.add(OpStatePair(op, state)); in add()
82 if (rect.intersects(mOps[i].state->mBounds)) { in intersects()
85 mOps[i].state->mBounds.left, mOps[i].state->mBounds.top, in intersects()
86 mOps[i].state->mBounds.right, mOps[i].state->mBounds.bottom); in intersects()
101 const DeferredDisplayState* state = mOps[i].state; in replay() local
102 renderer.restoreDisplayState(*state); in replay()
110 const Rect& bounds = state->mBounds; in replay()
128 const Rect &r = mOps[i].state->mBounds; in coversBounds()
181 bool canMergeWith(const DrawOp* op, const DeferredDisplayState* state) { in canMergeWith() argument
188 if (intersects(state->mBounds)) return false; in canMergeWith()
190 const DeferredDisplayState* lhs = state; in canMergeWith()
191 const DeferredDisplayState* rhs = mOps[0].state; in canMergeWith()
206 const int newFlags = state->mClipSideFlags; in canMergeWith()
208 const Rect& opBounds = state->mBounds; in canMergeWith()
239 virtual void add(DrawOp* op, const DeferredDisplayState* state, in add() argument
241 DrawBatch::add(op, state, opaqueOverBounds); in add()
243 const int newClipSideFlags = state->mClipSideFlags; in add()
245 if (newClipSideFlags & kClipSide_Left) mClipRect.left = state->mClip.left; in add()
246 if (newClipSideFlags & kClipSide_Top) mClipRect.top = state->mClip.top; in add()
247 if (newClipSideFlags & kClipSide_Right) mClipRect.right = state->mClip.right; in add()
248 if (newClipSideFlags & kClipSide_Bottom) mClipRect.bottom = state->mClip.bottom; in add()
289 StateOpBatch(const StateOp* op, const DeferredDisplayState* state) : mOp(op), mState(state) {} in StateOpBatch() argument
309 RestoreToCountBatch(const StateOp* op, const DeferredDisplayState* state, int restoreCount) : in RestoreToCountBatch() argument
310 mState(state), mRestoreCount(restoreCount) {} in RestoreToCountBatch()
473 DeferredDisplayState* const state = createState(); in addDrawOp() local
474 if (op->getLocalBounds(state->mBounds)) { in addDrawOp()
475 if (state->mBounds.isEmpty()) { in addDrawOp()
477 tryRecycleState(state); in addDrawOp()
481 state->mBounds.setEmpty(); in addDrawOp()
485 if (renderer.storeDisplayState(*state, getDrawOpDeferFlags())) { in addDrawOp()
486 tryRecycleState(state); in addDrawOp()
492 op->onDefer(renderer, deferInfo, *state); in addDrawOp()
499 && !state->mRoundRectClipState; in addDrawOp()
502 state->mClipSideFlags != kClipSide_ConservativeFull && in addDrawOp()
503 deferInfo.opaqueOverBounds && state->mBounds.contains(mBounds)) { in addDrawOp()
512 b->add(op, state, deferInfo.opaqueOverBounds); in addDrawOp()
524 if (state->mBounds.isEmpty()) { in addDrawOp()
527 b->add(op, state, deferInfo.opaqueOverBounds); in addDrawOp()
540 if (!((MergingDrawBatch*) targetBatch)->canMergeWith(op, state)) { in addDrawOp()
563 if (overBatch->intersects(state->mBounds)) { in addDrawOp()
595 targetBatch->add(op, state, deferInfo.opaqueOverBounds); in addDrawOp()
601 DeferredDisplayState* state = createState(); in storeStateOpBarrier() local
602 renderer.storeDisplayState(*state, getStateOpDeferFlags()); in storeStateOpBarrier()
603 mBatches.add(new StateOpBatch(op, state)); in storeStateOpBarrier()
614 DeferredDisplayState* state = createState(); in storeRestoreToCountBarrier() local
615 renderer.storeDisplayState(*state, getStateOpDeferFlags()); in storeRestoreToCountBarrier()
616 mBatches.add(new RestoreToCountBatch(op, state, newSaveCount)); in storeRestoreToCountBarrier()