Home | History | Annotate | Download | only in hwui

Lines Matching defs:clip

277         const Rect* clip = &mTilingClip;
279 clip = &(snapshot->layer->clipRect);
282 startTiling(*clip, getViewportHeight(), opaque, expand);
286 void OpenGLRenderer::startTiling(const Rect& clip, int windowHeight, bool opaque, bool expand) {
290 int leftNotZero = (clip.left > 0) ? 1 : 0;
291 int topNotZero = (windowHeight - clip.bottom > 0) ? 1 : 0;
294 clip.left - leftNotZero,
295 windowHeight - clip.bottom - topNotZero,
296 clip.right - clip.left + leftNotZero + 1,
297 clip.bottom - clip.top + topNotZero + 1,
300 mCaches.startTiling(clip.left, windowHeight - clip.bottom,
301 clip.right - clip.left, clip.bottom - clip.top, opaque);
355 Rect clip(*currentClipRect());
356 clip.snapToPixelBoundaries();
359 // the entire clip region
361 dirtyLayerUnchecked(clip, getRegion());
365 info.clipLeft = clip.left;
366 info.clipTop = clip.top;
367 info.clipRight = clip.right;
368 info.clipBottom = clip.bottom;
384 // Scissor may have been modified, reset dirty clip
427 const Rect* clip = &mTilingClip;
430 mCaches.setScissor(clip->left, firstSnapshot()->getViewportHeight() - clip->bottom,
431 clip->right - clip->left, clip->bottom - clip->top);
603 // force matrix/clip isolation for layer
615 void OpenGLRenderer::calculateLayerBoundsAndClip(Rect& bounds, Rect& clip, bool fboLayer) {
633 clip.set(bounds);
636 inverse.mapRect(clip);
637 clip.snapToPixelBoundaries();
638 if (clip.intersect(untransformedBounds)) {
639 clip.translate(-untransformedBounds.left, -untransformedBounds.top);
642 clip.setEmpty();
650 void OpenGLRenderer::updateSnapshotIgnoreForLayer(const Rect& bounds, const Rect& clip,
654 (fboLayer && clip.isEmpty())) {
667 // operations will be able to store and restore the current clip and transform info, and
671 Rect clip;
672 calculateLayerBoundsAndClip(bounds, clip, true);
673 updateSnapshotIgnoreForLayer(bounds, clip, true, getAlphaDirect(paint));
677 mSnapshot->resetClip(clip.left, clip.top, clip.right, clip.bottom);
699 * - Change viewport, clip and projection matrix
704 * general case. FBOs are used, as an optimization, when the "clip to layer" flag
745 Rect clip;
747 calculateLayerBoundsAndClip(bounds, clip, fboLayer);
748 updateSnapshotIgnoreForLayer(bounds, clip, fboLayer, getAlphaDirect(paint));
779 return createFboLayer(layer, bounds, clip);
806 bool OpenGLRenderer::createFboLayer(Layer* layer, Rect& bounds, Rect& clip) {
807 layer->clipRect.set(clip);
814 mSnapshot->resetClip(clip.left, clip.top, clip.right, clip.bottom);
838 mCaches.setScissor(clip.left - 1.0f, bounds.getHeight() - clip.bottom - 1.0f,
839 clip.getWidth() + 2.0f, clip.getHeight() + 2.0f);
1072 // clip to the area of the layer the mask can be larger
1162 // TODO: Reject quads outside of the clip
1286 // against their initial clip rect, and the current clip
1355 // op partially clipped, so record which sides are clipped for clip-aware merging
1401 * in the draw path. Instead, clipping is done ahead of time - either as a single clip rect (when at
1404 * This method should be called when restoreDisplayState() won't be restoring the clip
1421 Rect clip(*currentClipRect());
1422 clip.snapToPixelBoundaries();
1424 if (mCaches.setScissor(clip.left, getViewportHeight() - clip.bottom,
1425 clip.getWidth(), clip.getHeight())) {
1477 // stash and disable the outline clip state, since stencil doesn't account for outline
2455 // No need to check against the clip, we fill the clip region
2458 Rect clip(*currentClipRect());
2459 clip.snapToPixelBoundaries();
2465 drawColorRect(clip.left, clip.top, clip.right, clip.bottom, &paint, true);
2710 const Rect* clip = pureTranslate ? mSnapshot->clipRect : &mSnapshot->getLocalClip();
2716 if (fontRenderer.renderPosText(paint, clip, text, 0, bytesCount, count, x, y,
2807 const Rect* clip = !pureTranslate ? NULL : currentClipRect();
2818 status = fontRenderer.renderPosText(&paintCopy, clip, text, 0, bytesCount, count, x, y,
2821 status = fontRenderer.renderPosText(paint, clip, text, 0, bytesCount, count, x, y,
2855 const Rect* clip = &mSnapshot->getLocalClip();
2860 if (fontRenderer.renderTextOnPath(paint, clip, text, 0, bytesCount, count, path,
3173 bool ignoreTransform, bool dirty, bool clip) {
3209 if (clip && quickRejectSetupScissor(left, top, right, bottom)) {