/* this will draw a full-resource quad, so ignore existing data */
if (util_blit_covers_whole_resource(info))
pctx->invalidate_resource(pctx, info->dst.resource);
+ ctx->blitting = true;
zink_blit_begin(ctx, ZINK_BLIT_SAVE_FB | ZINK_BLIT_SAVE_FS | ZINK_BLIT_SAVE_TEXTURES);
if (stencil_blit) {
} else {
util_blitter_blit(ctx->blitter, info);
}
+ ctx->blitting = false;
end:
if (needs_present_readback)
zink_kopper_present_readback(ctx, src);
surf = create_clear_surface(pctx, pres, level, box);
util_blitter_save_framebuffer(ctx->blitter, &ctx->fb_state);
set_clear_fb(pctx, surf, NULL);
+ ctx->blitting = true;
pctx->clear(pctx, PIPE_CLEAR_COLOR0, &scissor, &color, 0, 0);
util_blitter_restore_fb_state(ctx->blitter);
+ ctx->blitting = false;
} else {
float depth = 0.0;
uint8_t stencil = 0;
flags |= PIPE_CLEAR_STENCIL;
surf = create_clear_surface(pctx, pres, level, box);
util_blitter_save_framebuffer(ctx->blitter, &ctx->fb_state);
+ ctx->blitting = true;
set_clear_fb(pctx, NULL, surf);
pctx->clear(pctx, flags, &scissor, NULL, depth, stencil);
util_blitter_restore_fb_state(ctx->blitter);
+ ctx->blitting = false;
}
/* this will never destroy the surface */
pipe_surface_reference(&surf, NULL);
util_blitter_save_framebuffer(ctx->blitter, &ctx->fb_state);
set_clear_fb(pctx, dst, NULL);
struct pipe_scissor_state scissor = {dstx, dsty, dstx + width, dsty + height};
+ ctx->blitting = true;
pctx->clear(pctx, PIPE_CLEAR_COLOR0, &scissor, color, 0, 0);
util_blitter_restore_fb_state(ctx->blitter);
+ ctx->blitting = false;
if (!render_condition_enabled && render_condition_active)
zink_start_conditional_render(ctx);
ctx->render_condition_active = render_condition_active;
if (!cur_attachment) {
util_blitter_save_framebuffer(ctx->blitter, &ctx->fb_state);
set_clear_fb(pctx, NULL, dst);
+ ctx->blitting = true;
}
struct pipe_scissor_state scissor = {dstx, dsty, dstx + width, dsty + height};
pctx->clear(pctx, clear_flags, &scissor, NULL, depth, stencil);
- if (!cur_attachment)
+ if (!cur_attachment) {
util_blitter_restore_fb_state(ctx->blitter);
+ ctx->blitting = false;
+ }
if (!render_condition_enabled && render_condition_active)
zink_start_conditional_render(ctx);
ctx->render_condition_active = render_condition_active;
src_view = ctx->base.create_sampler_view(&ctx->base, src, &src_templ);
zink_blit_begin(ctx, ZINK_BLIT_SAVE_FB | ZINK_BLIT_SAVE_FS | ZINK_BLIT_SAVE_TEXTURES);
+ ctx->blitting = true;
util_blitter_blit_generic(ctx->blitter, dst_view, &dstbox,
src_view, &dstbox, ctx->fb_state.width, ctx->fb_state.height,
PIPE_MASK_RGBAZS, PIPE_TEX_FILTER_NEAREST, NULL,
false, false, 0);
-
+ ctx->blitting = false;
pipe_sampler_view_reference(&src_view, NULL);
csurf->transient_init = true;
}