diff options
author | José Fonseca <[email protected]> | 2010-03-13 16:13:26 +0000 |
---|---|---|
committer | José Fonseca <[email protected]> | 2010-03-13 16:13:26 +0000 |
commit | bf40c346637325862d6d9cdbc9838c5726abc0c0 (patch) | |
tree | 319879161ef4693a983a05c6381bf4fd41fc801e /src/gallium/drivers/llvmpipe/lp_surface.c | |
parent | 3abc7b985ce0787c5103d1a86bd0ba07b127a82f (diff) |
llvmpipe: Ensure the context is flushed before modifying textures.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_surface.c')
-rw-r--r-- | src/gallium/drivers/llvmpipe/lp_surface.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_surface.c b/src/gallium/drivers/llvmpipe/lp_surface.c index 6110b0a193e..ca3d62c3613 100644 --- a/src/gallium/drivers/llvmpipe/lp_surface.c +++ b/src/gallium/drivers/llvmpipe/lp_surface.c @@ -27,6 +27,7 @@ #include "util/u_rect.h" #include "lp_context.h" +#include "lp_flush.h" #include "lp_surface.h" @@ -36,6 +37,20 @@ lp_surface_copy(struct pipe_context *pipe, struct pipe_surface *src, unsigned srcx, unsigned srcy, unsigned width, unsigned height) { + llvmpipe_flush_texture(pipe, + dest->texture, dest->face, dest->level, + 0, /* flush_flags */ + FALSE, /* read_only */ + FALSE, /* cpu_access */ + FALSE); /* do_not_flush */ + + llvmpipe_flush_texture(pipe, + src->texture, src->face, src->level, + 0, /* flush_flags */ + TRUE, /* read_only */ + FALSE, /* cpu_access */ + FALSE); /* do_not_flush */ + util_surface_copy(pipe, FALSE, dest, destx, desty, src, srcx, srcy, |