Lines Matching refs:clip

243 void BakedOpRenderer::setupStencilRectList(const ClipBase* clip) {
244 LOG_ALWAYS_FATAL_IF(clip->mode != ClipMode::RectangleList, "can't rectlist clip without rectlist");
245 auto&& rectList = reinterpret_cast<const ClipRectList*>(clip)->rectList;
256 bounds.doIntersect(clip->rect);
277 void BakedOpRenderer::setupStencilRegion(const ClipBase* clip) {
278 LOG_ALWAYS_FATAL_IF(clip->mode != ClipMode::Region, "can't region clip without region");
279 auto&& region = reinterpret_cast<const ClipRegion*>(clip)->region;
282 SkRegion::Cliperator it(region, clip->rect.toSkIRect());
294 void BakedOpRenderer::prepareRender(const Rect* dirtyBounds, const ClipBase* clip) {
296 mRenderState.scissor().setEnabled(clip != nullptr);
297 if (clip) {
298 mRenderState.scissor().set(mRenderTarget.viewportHeight, clip->rect);
304 if (CC_UNLIKELY(clip && clip->mode != ClipMode::Rectangle)) {
307 if (mRenderTarget.lastStencilClip != clip) {
309 mRenderTarget.lastStencilClip = clip;
321 if (clip->mode == ClipMode::RectangleList) {
322 setupStencilRectList(clip);
324 setupStencilRegion(clip);
330 if (CC_LIKELY(clip->mode == ClipMode::RectangleList)) {
331 auto&& rectList = reinterpret_cast<const ClipRectList*>(clip)->rectList;
337 // either scissor or no clip, so disable stencil test
348 void BakedOpRenderer::renderGlopImpl(const Rect* dirtyBounds, const ClipBase* clip,
350 prepareRender(dirtyBounds, clip);
359 auto&& clip = state.computedState.clipRect();
360 info.clipLeft = clip.left;
361 info.clipTop = clip.top;
362 info.clipRight = clip.right;
363 info.clipBottom = clip.bottom;