[Mesa-dev] [PATCH 4/7] radeonsi: handle NULL colorbuffers correctly

Michel Dänzer michel at daenzer.net
Wed Jan 8 18:51:58 PST 2014


On Mit, 2014-01-08 at 18:23 +0100, Marek Olšák wrote:
> 
> diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
> index 3666a11..ba73401 100644
> --- a/src/gallium/drivers/radeonsi/si_state.c
> +++ b/src/gallium/drivers/radeonsi/si_state.c
[...]
> @@ -2136,16 +2143,11 @@ static void si_set_framebuffer_state(struct pipe_context *ctx,
[...]
>  	si_set_msaa_state(rctx, pm4, nr_samples);
>  	rctx->fb_log_samples = util_logbase2(nr_samples);
> -	rctx->fb_cb0_is_integer = state->nr_cbufs &&
> +	rctx->fb_cb0_is_integer = state->nr_cbufs && state->cbufs[0] &&
>  				  util_format_is_pure_integer(state->cbufs[0]->format);

Should this check the first non-NULL cbuf now instead of always
cbufs[0]?

If not,

Reviewed-by: Michel Dänzer <michel.daenzer at amd.com>


-- 
Earthling Michel Dänzer            |                  http://www.amd.com
Libre software enthusiast          |                Mesa and X developer



More information about the mesa-dev mailing list