Module: Mesa Branch: master Commit: 2b2c61f0df5c18355b65772d21be36339ba5e1d9 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=2b2c61f0df5c18355b65772d21be36339ba5e1d9
Author: Roland Scheidegger <srol...@vmware.com> Date: Fri Sep 1 01:48:42 2017 +0200 st/mesa: fix view template initialization in try_pbo_readpixels I think this is what the code was meant to do, albeit as far as I can tell the redundant initialization some analyzers complain about should work as well just fine (only the first layer will be used, if the view contains one or more layers doesn't really matter). Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102467 Reviewed-by: Brian Paul <bri...@vmware.com> Reviewed-by: Marek Olšák <marek.ol...@amd.com> Cc: mesa-sta...@lists.freedesktop.org --- src/mesa/state_tracker/st_cb_readpixels.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_cb_readpixels.c b/src/mesa/state_tracker/st_cb_readpixels.c index 0bcf2eb4fd..84dd2d548e 100644 --- a/src/mesa/state_tracker/st_cb_readpixels.c +++ b/src/mesa/state_tracker/st_cb_readpixels.c @@ -175,7 +175,7 @@ try_pbo_readpixels(struct st_context *st, struct st_renderbuffer *strb, if (view_target != PIPE_TEXTURE_3D) { templ.u.tex.first_layer = surface->u.tex.first_layer; - templ.u.tex.last_layer = templ.u.tex.last_layer; + templ.u.tex.last_layer = templ.u.tex.first_layer; } else { addr.constants.layer_offset = surface->u.tex.first_layer; } _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-commit