st/mesa: fix glCopyPixels bugs/crashes when src region need clipping
authorBrian Paul <brianp@vmware.com>
Wed, 17 Mar 2010 16:06:27 +0000 (10:06 -0600)
committerBrian Paul <brianp@vmware.com>
Wed, 17 Mar 2010 16:06:27 +0000 (10:06 -0600)
Use the _mesa_clip_readpixels() function to clip the src region against
the buffer's bounds.  Neatly, the resulting pixel unpack object's
SkipPixels/SkipRows fields can be used to determine the position of the
region in the destination texture.

Fixes crash in progs/samples/copy.c and probably other cases.


No differences found