i965: Fix z_offset computation in intel_miptree_unmap_depthstencil()
authorAnuj Phogat <anuj.phogat@gmail.com>
Mon, 14 Jul 2014 23:16:47 +0000 (16:16 -0700)
committerAnuj Phogat <anuj.phogat@gmail.com>
Thu, 17 Jul 2014 22:52:27 +0000 (15:52 -0700)
commit984a02ba556802775d63a9ce77b4dac567bf8680
tree59bf7cfd267be4309a184c5352c3b7f3c9071eb6
parent5d9f5cd35b63e8d7fdb42a5ad26c53d2a19f6985
i965: Fix z_offset computation in intel_miptree_unmap_depthstencil()

The bug is triggered by using glTexSubImage2d() with GL_DEPTH_STENCIL
as base internal format and non-zero x, y offsets. Currently x, y
offsets are ignored while updating the texture image.

Fixes Khronos GLES3 CTS tests:
npot_tex_sub_image_2d
npot_tex_sub_image_3d
npot_pbo_tex_sub_image_2d
npot_pbo_tex_sub_image_2d

Cc: <mesa-stable@lists.freedesktop.org>
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
src/mesa/drivers/dri/i965/intel_mipmap_tree.c