gallium/util: don't use blocksize for minify for assertions
authorRoland Scheidegger <sroland@vmware.com>
Tue, 14 Jun 2016 01:31:20 +0000 (03:31 +0200)
committerRoland Scheidegger <sroland@vmware.com>
Tue, 14 Jun 2016 15:03:34 +0000 (17:03 +0200)
commitafbf5888f508634d30008b5e898c0f7be5d02785
tree6402ce4bafbf63bbbea2f9eb005f87355c3915e0
parentf4184d5450c12e107d3e41ae29e5927c75543259
gallium/util: don't use blocksize for minify for assertions

The previous assertions required for texture sizes smaller than block_size
that src_box.x + src_box.width still be block size.
(e.g. for a texture with width 3, and src_box.x = 0, src_box.width would
have to be 4 to not assert.)
This caused some assertions with some other state tracker.
It looks though like callers aren't expected to round up widths to block sizes
(for sizes larger than block size the assertion would still have verified it
wouldn't have been rounded up) so we simply shouldn't use a minify which
rounds up to block size.
(No piglit change with llvmpipe.)

Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
src/gallium/auxiliary/util/u_surface.c