OSDN Git Service

svga: move svga_texture() casts/calls in svga_surface_copy()
authorBrian Paul <brianp@vmware.com>
Thu, 19 Jan 2012 18:37:00 +0000 (11:37 -0700)
committerBrian Paul <brianp@vmware.com>
Thu, 19 Jan 2012 23:23:12 +0000 (16:23 -0700)
commit7f2e12812a2208330ef8704e7c4721ececd2aab3
tree64d7eed2de0abbc448b38c84532f615879bfc99e
parentfdae0eaf222f271bfbc7e71d8561eb8b90685ae5
svga: move svga_texture() casts/calls in svga_surface_copy()

To fix failed assertions when calling glCopyBufferSubData().

svga_texture() asserts that the resource is a texture.  Simply move the
calls to svga_texture() after the code that handles non-texture copies
so that we don't call it with non-texture resources.

Fixes glean bufferObject failure.

NOTE: This is a candidate for the 8.0 branch.

Reviewed-by: José Fonseca <jfonseca@vmware.com>
src/gallium/drivers/svga/svga_pipe_blit.c