mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-29 22:30:24 +01:00
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>
(cherry picked from commit 7f2e12812a)
This commit is contained in:
parent
2bf8f39cc8
commit
dad7547b98
1 changed files with 4 additions and 2 deletions
|
|
@ -44,8 +44,7 @@ static void svga_surface_copy(struct pipe_context *pipe,
|
|||
const struct pipe_box *src_box)
|
||||
{
|
||||
struct svga_context *svga = svga_context(pipe);
|
||||
struct svga_texture *stex = svga_texture(src_tex);
|
||||
struct svga_texture *dtex = svga_texture(dst_tex);
|
||||
struct svga_texture *stex, *dtex;
|
||||
/* struct pipe_screen *screen = pipe->screen;
|
||||
SVGA3dCopyBox *box;
|
||||
enum pipe_error ret;
|
||||
|
|
@ -63,6 +62,9 @@ static void svga_surface_copy(struct pipe_context *pipe,
|
|||
return;
|
||||
}
|
||||
|
||||
stex = svga_texture(src_tex);
|
||||
dtex = svga_texture(dst_tex);
|
||||
|
||||
#if 0
|
||||
srcsurf = screen->get_tex_surface(screen, src_tex,
|
||||
src_level, src_box->z, src_box->z,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue