set miptree pitch to region pitch after allocating the region in st_miptree_create()

This fixes rendering with small (4x4) textures with softpipe.
Haven't yet tested with i915.
This commit is contained in:
Brian 2007-09-27 16:33:01 -06:00
parent 28b315dc1a
commit 7966e479dc

View file

@ -89,6 +89,7 @@ st_miptree_create(struct pipe_context *pipe,
/* note: it's OK to pass 'pitch' as 'width' here: */
mt->region = pipe->region_alloc(pipe, mt->cpp, mt->pitch,
mt->total_height, flags);
mt->pitch = mt->region->pitch; /*XXX NEW */
}
if (!mt->region) {