intel: Refactor intel_miptree_copy_teximage()
authorChad Versace <chad.versace@linux.intel.com>
Thu, 17 Nov 2011 06:26:38 +0000 (22:26 -0800)
committerChad Versace <chad.versace@linux.intel.com>
Tue, 22 Nov 2011 00:58:38 +0000 (16:58 -0800)
commit278e77a1192d5251c5b70a555e676f72b446e8e1
tree92c87ad8cbca2a3b1ad2bd3bef15b3d2abec61a5
parentc2ddde70daece24d1eb7185946032158993a9e4d
intel: Refactor intel_miptree_copy_teximage()

Extract the body of the inner loop into a new function,
intel_miptree_copy_slice().

This is in preparation for adding support for separate stencil and HiZ to
intel_miptree_copy_teximage(). When copying a slice of a depthstencil
miptree that uses separate stencil, we will also need to copy the
corresponding slice of the stencil miptree. The easiest way to do this
will be to call intel_miptree_copy_slice() recursively. Analogous
reasoning applies to copying a slice of a depth miptree with HiZ.

Reviewed-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
src/mesa/drivers/dri/intel/intel_mipmap_tree.c