unsigned clear_buffers,
const union pipe_color_union *color,
double depth, unsigned stencil,
- void *custom_blend, void *custom_dsa)
+ void *custom_blend, void *custom_dsa,
+ bool msaa)
{
struct blitter_context_priv *ctx = (struct blitter_context_priv*)blitter;
struct pipe_context *pipe = ctx->base.pipe;
if (num_layers > 1 && ctx->has_layered) {
blitter_get_vs_func get_vs = get_vs_layered;
- blitter_set_common_draw_rect_state(ctx, false, false);
+ blitter_set_common_draw_rect_state(ctx, false, msaa);
blitter->draw_rectangle(blitter, ctx->velem_state, get_vs,
0, 0, width, height,
(float) depth, num_layers, type, &attrib);
else
get_vs = get_vs_passthrough_pos;
- blitter_set_common_draw_rect_state(ctx, false, false);
+ blitter_set_common_draw_rect_state(ctx, false, msaa);
blitter->draw_rectangle(blitter, ctx->velem_state, get_vs,
0, 0, width, height,
(float) depth, 1, type, &attrib);
unsigned width, unsigned height, unsigned num_layers,
unsigned clear_buffers,
const union pipe_color_union *color,
- double depth, unsigned stencil)
+ double depth, unsigned stencil,
+ bool msaa)
{
util_blitter_clear_custom(blitter, width, height, num_layers,
clear_buffers, color, depth, stencil,
- NULL, NULL);
+ NULL, NULL, msaa);
}
void util_blitter_custom_clear_depth(struct blitter_context *blitter,
{
static const union pipe_color_union color;
util_blitter_clear_custom(blitter, width, height, 0, 0, &color, depth, 0,
- NULL, custom_dsa);
+ NULL, custom_dsa, false);
}
void util_blitter_default_dst_texture(struct pipe_surface *dst_templ,
/* Clear using the blitter. */
r300_blitter_begin(r300, R300_CLEAR);
util_blitter_clear(r300->blitter, width, height, 1,
- buffers, color, depth, stencil);
+ buffers, color, depth, stencil,
+ util_framebuffer_get_num_samples(fb) > 1);
r300_blitter_end(r300);
} else if (r300->zmask_clear.dirty ||
r300->hiz_clear.dirty ||
r600_blitter_begin(ctx, R600_CLEAR);
util_blitter_clear(rctx->blitter, fb->width, fb->height,
util_framebuffer_get_num_layers(fb),
- buffers, color, depth, stencil);
+ buffers, color, depth, stencil,
+ util_framebuffer_get_num_samples(fb) > 1);
r600_blitter_end(ctx);
/* disable fast clear */
si_blitter_begin(sctx, SI_CLEAR);
util_blitter_clear(sctx->blitter, fb->width, fb->height,
util_framebuffer_get_num_layers(fb),
- buffers, color, depth, stencil);
+ buffers, color, depth, stencil,
+ sctx->framebuffer.nr_samples > 1);
si_blitter_end(sctx);
if (sctx->db_depth_clear) {