aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPierre-Eric Pelloux-Prayer <[email protected]>2019-10-29 19:45:48 +0100
committerPierre-Eric Pelloux-Prayer <[email protected]>2019-10-31 12:30:53 +0100
commit8a723282e3f7a312ab0ca3aa9157e5b76ec182af (patch)
treea2b1e57125f5d1a313ac480a1421e76b30579730 /src
parentb087b7bd9052bf40f80473074508f1961265ec6b (diff)
mesa: enable msaa in clear_with_quad if needed
If the DrawBuffer sample count is > 1 and msaa is enabled we must also enable msaa when clearing it. Fixes: ea5b7de138b ("radeonsi: make gl_SampleMaskIn = 0x1 when MSAA is disabled") Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/1991 Reviewed-by: Marek Olšák <[email protected]> Tested-by: Witold Baryluk <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/state_tracker/st_cb_clear.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c
index 06fb9798c68..1e28e27586a 100644
--- a/src/mesa/state_tracker/st_cb_clear.c
+++ b/src/mesa/state_tracker/st_cb_clear.c
@@ -325,6 +325,7 @@ clear_with_quad(struct gl_context *ctx, unsigned clear_buffers)
cso_set_stream_outputs(cso, 0, NULL, NULL);
cso_set_sample_mask(cso, ~0);
cso_set_min_samples(cso, 1);
+ st->clear.raster.multisample = st->state.fb_num_samples > 1;
cso_set_rasterizer(cso, &st->clear.raster);
/* viewport state: viewport matching window dims */