From a40b76143d8b929412bed6fbed04810902844c40 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Thu, 23 Feb 2017 00:30:49 +0100 Subject: [PATCH] st/mesa: reset sample_mask, min_sample, and render_condition for PBO ops Cc: 13.0 17.0 Reviewed-by: Brian Paul --- src/mesa/state_tracker/st_cb_readpixels.c | 7 +++++++ src/mesa/state_tracker/st_cb_texture.c | 6 ++++++ 2 files changed, 13 insertions(+) diff --git a/src/mesa/state_tracker/st_cb_readpixels.c b/src/mesa/state_tracker/st_cb_readpixels.c index ea91bb93b87..5ce2421bbfb 100644 --- a/src/mesa/state_tracker/st_cb_readpixels.c +++ b/src/mesa/state_tracker/st_cb_readpixels.c @@ -139,9 +139,16 @@ try_pbo_readpixels(struct st_context *st, struct st_renderbuffer *strb, CSO_BIT_DEPTH_STENCIL_ALPHA | CSO_BIT_STREAM_OUTPUTS | CSO_BIT_PAUSE_QUERIES | + CSO_BIT_SAMPLE_MASK | + CSO_BIT_MIN_SAMPLES | + CSO_BIT_RENDER_CONDITION | CSO_BITS_ALL_SHADERS)); cso_save_constant_buffer_slot0(cso, PIPE_SHADER_FRAGMENT); + cso_set_sample_mask(cso, ~0); + cso_set_min_samples(cso, 1); + cso_set_render_condition(cso, NULL, FALSE, 0); + /* Set up the sampler_view */ { struct pipe_sampler_view templ; diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c index 7c493fc1143..bc6f108a860 100644 --- a/src/mesa/state_tracker/st_cb_texture.c +++ b/src/mesa/state_tracker/st_cb_texture.c @@ -1155,9 +1155,15 @@ try_pbo_upload_common(struct gl_context *ctx, CSO_BIT_RASTERIZER | CSO_BIT_STREAM_OUTPUTS | CSO_BIT_PAUSE_QUERIES | + CSO_BIT_SAMPLE_MASK | + CSO_BIT_MIN_SAMPLES | + CSO_BIT_RENDER_CONDITION | CSO_BITS_ALL_SHADERS)); cso_save_constant_buffer_slot0(cso, PIPE_SHADER_FRAGMENT); + cso_set_sample_mask(cso, ~0); + cso_set_min_samples(cso, 1); + cso_set_render_condition(cso, NULL, FALSE, 0); /* Set up the sampler_view */ { -- 2.30.2