From: Nanley Chery Date: Thu, 3 Mar 2016 23:49:13 +0000 (-0800) Subject: isl: Fix RenderTargetViewExtent for mipmapped 3D surfaces X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a6fb62a86441ce7296f9d06cf7a71d2f51f3a3f5;p=mesa.git isl: Fix RenderTargetViewExtent for mipmapped 3D surfaces Match the comment stated above the assignment. Signed-off-by: Nanley Chery Reviewed-by: Jason Ekstrand --- diff --git a/src/intel/isl/isl_surface_state.c b/src/intel/isl/isl_surface_state.c index fe8f07cfe30..f3390a6c553 100644 --- a/src/intel/isl/isl_surface_state.c +++ b/src/intel/isl/isl_surface_state.c @@ -346,7 +346,8 @@ isl_genX(surf_fill_state_s)(const struct isl_device *dev, void *state, * indicates the extent of the accessible 'R' coordinates minus 1 on * the LOD currently being rendered to. */ - s.RenderTargetViewExtent = info->surf->logical_level0_px.depth - 1; + s.RenderTargetViewExtent = isl_minify(info->surf->logical_level0_px.depth, + info->view->base_level) - 1; break; default: unreachable(!"bad SurfaceType");