From: Park, Jeongmin Date: Sat, 7 Feb 2015 08:53:48 +0000 (+0900) Subject: st/dri: Make depth buffer optional for postprocessing X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0467a52dc3f7d51eeb51179ce2f9871758ecacb1;p=mesa.git st/dri: Make depth buffer optional for postprocessing Since only pp_jimenezmlaa uses depth buffer, we can make it optional. Signed-off-by: Marek Olšák --- diff --git a/src/gallium/state_trackers/dri/dri_drawable.c b/src/gallium/state_trackers/dri/dri_drawable.c index eda2d5232c5..b8afe6c4d23 100644 --- a/src/gallium/state_trackers/dri/dri_drawable.c +++ b/src/gallium/state_trackers/dri/dri_drawable.c @@ -418,7 +418,7 @@ dri_postprocessing(struct dri_context *ctx, struct pipe_resource *src = drawable->textures[att]; struct pipe_resource *zsbuf = drawable->textures[ST_ATTACHMENT_DEPTH_STENCIL]; - if (ctx->pp && src && zsbuf) + if (ctx->pp && src) pp_run(ctx->pp, src, src, zsbuf); } diff --git a/src/gallium/state_trackers/dri/drisw.c b/src/gallium/state_trackers/dri/drisw.c index 8d9acd6af51..5f69a2d670e 100644 --- a/src/gallium/state_trackers/dri/drisw.c +++ b/src/gallium/state_trackers/dri/drisw.c @@ -172,7 +172,7 @@ drisw_swap_buffers(__DRIdrawable *dPriv) ptex = drawable->textures[ST_ATTACHMENT_BACK_LEFT]; if (ptex) { - if (ctx->pp && drawable->textures[ST_ATTACHMENT_DEPTH_STENCIL]) + if (ctx->pp) pp_run(ctx->pp, ptex, ptex, drawable->textures[ST_ATTACHMENT_DEPTH_STENCIL]); ctx->st->flush(ctx->st, ST_FLUSH_FRONT, NULL);