diff options
author | Marek Olšák <[email protected]> | 2012-04-11 16:00:09 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2012-04-24 01:39:22 +0200 |
commit | 428855eea3e99d94474df6df0cb8dfc4a8819702 (patch) | |
tree | f6b390ea6d4fd4697b524e6c01c76242b70b058e /src/gallium/drivers/r600/r600_pipe.c | |
parent | e54cc2c070b30dd9b14bf9aedf93138b660c867f (diff) |
r600g: don't share u_upload_mgr with u_vbuf, create its own
Diffstat (limited to 'src/gallium/drivers/r600/r600_pipe.c')
-rw-r--r-- | src/gallium/drivers/r600/r600_pipe.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c index c4c27ab526b..7dfa2bfb3a7 100644 --- a/src/gallium/drivers/r600/r600_pipe.c +++ b/src/gallium/drivers/r600/r600_pipe.c @@ -28,6 +28,7 @@ #include "util/u_blitter.h" #include "util/u_format_s3tc.h" #include "util/u_simple_shaders.h" +#include "util/u_upload_mgr.h" #include "vl/vl_decoder.h" #include "vl/vl_video_buffer.h" #include "os/os_time.h" @@ -194,6 +195,9 @@ static void r600_destroy_context(struct pipe_context *context) if (rctx->vbuf_mgr) { u_vbuf_destroy(rctx->vbuf_mgr); } + if (rctx->uploader) { + u_upload_destroy(rctx->uploader); + } util_slab_destroy(&rctx->pool_transfers); r600_update_num_contexts(rctx->screen, -1); @@ -304,6 +308,12 @@ static struct pipe_context *r600_create_context(struct pipe_screen *screen, void if (!rctx->vbuf_mgr) goto fail; + rctx->uploader = u_upload_create(&rctx->context, 1024 * 1024, 256, + PIPE_BIND_INDEX_BUFFER | + PIPE_BIND_CONSTANT_BUFFER); + if (!rctx->uploader) + goto fail; + rctx->blitter = util_blitter_create(&rctx->context); if (rctx->blitter == NULL) goto fail; |