hud->pipe = pipe;
hud->cso = cso;
- hud->uploader = u_upload_create(pipe, 256 * 1024, 16,
+ hud->uploader = u_upload_create(pipe, 256 * 1024,
PIPE_BIND_VERTEX_BUFFER);
/* font */
}
if (!pc->upload) {
- pc->upload = u_upload_create(pc->pipe, 4096, 4, PIPE_BIND_INDEX_BUFFER);
+ pc->upload = u_upload_create(pc->pipe, 4096, PIPE_BIND_INDEX_BUFFER);
}
u_upload_alloc(pc->upload, 0, new_ib.index_size * new_info.count, 4,
for (i = 0; i < 4; i++)
ctx->vertices[i][0][3] = 1; /*v.w*/
- ctx->upload = u_upload_create(pipe, 65536, 4, PIPE_BIND_VERTEX_BUFFER);
+ ctx->upload = u_upload_create(pipe, 65536, PIPE_BIND_VERTEX_BUFFER);
return &ctx->base;
}
struct pipe_context *pipe;
unsigned default_size; /* Minimum size of the upload buffer, in bytes. */
- unsigned alignment; /* Alignment of each sub-allocation. */
unsigned bind; /* Bitmask of PIPE_BIND_* flags. */
unsigned map_flags; /* Bitmask of PIPE_TRANSFER_* flags. */
boolean map_persistent; /* If persistent mappings are supported. */
struct u_upload_mgr *u_upload_create( struct pipe_context *pipe,
unsigned default_size,
- unsigned alignment,
unsigned bind )
{
struct u_upload_mgr *upload = CALLOC_STRUCT( u_upload_mgr );
upload->pipe = pipe;
upload->default_size = default_size;
- upload->alignment = alignment;
upload->bind = bind;
upload->map_persistent =
*
* \param pipe Pipe driver.
* \param default_size Minimum size of the upload buffer, in bytes.
- * \param alignment Alignment of each suballocation in the upload buffer.
* \param bind Bitmask of PIPE_BIND_* flags.
*/
struct u_upload_mgr *u_upload_create( struct pipe_context *pipe,
unsigned default_size,
- unsigned alignment,
unsigned bind );
/**
mgr->translate_cache = translate_cache_create();
memset(mgr->fallback_vbs, ~0, sizeof(mgr->fallback_vbs));
- mgr->uploader = u_upload_create(pipe, 1024 * 1024, 4,
+ mgr->uploader = u_upload_create(pipe, 1024 * 1024,
PIPE_BIND_VERTEX_BUFFER);
return mgr;
c->pipe = pipe;
- c->upload = u_upload_create(pipe, 128 * 1024, 4, PIPE_BIND_VERTEX_BUFFER);
+ c->upload = u_upload_create(pipe, 128 * 1024, PIPE_BIND_VERTEX_BUFFER);
if (!c->upload)
return false;
fd3_query_context_init(pctx);
- fd3_ctx->border_color_uploader = u_upload_create(pctx, 4096,
- BORDER_COLOR_UPLOAD_SIZE, 0);
+ fd3_ctx->border_color_uploader = u_upload_create(pctx, 4096, 0);
return pctx;
}
fd4_query_context_init(pctx);
- fd4_ctx->border_color_uploader = u_upload_create(pctx, 4096,
- BORDER_COLOR_UPLOAD_SIZE, 0);
+ fd4_ctx->border_color_uploader = u_upload_create(pctx, 4096, 0);
return pctx;
}
* These must be called last as u_upload/u_blitter are clients of the pipe
* context.
*/
- ilo->uploader = u_upload_create(&ilo->base, 1024 * 1024, 16,
+ ilo->uploader = u_upload_create(&ilo->base, 1024 * 1024,
PIPE_BIND_CONSTANT_BUFFER | PIPE_BIND_INDEX_BUFFER);
if (!ilo->uploader) {
ilo_context_destroy(&ilo->base);
r300->context.create_video_codec = vl_create_decoder;
r300->context.create_video_buffer = vl_video_buffer_create;
- r300->uploader = u_upload_create(&r300->context, 256 * 1024, 4,
+ r300->uploader = u_upload_create(&r300->context, 256 * 1024,
PIPE_BIND_CUSTOM);
r300->blitter = util_blitter_create(&r300->context);
if (!rctx->allocator_so_filled_size)
return false;
- rctx->uploader = u_upload_create(&rctx->b, 1024 * 1024, 256,
+ rctx->uploader = u_upload_create(&rctx->b, 1024 * 1024,
PIPE_BIND_INDEX_BUFFER |
PIPE_BIND_CONSTANT_BUFFER);
if (!rctx->uploader)
svga->const0_upload = u_upload_create(&svga->pipe,
CONST0_UPLOAD_DEFAULT_SIZE,
- CONST0_UPLOAD_ALIGNMENT,
PIPE_BIND_CONSTANT_BUFFER);
if (!svga->const0_upload)
goto cleanup;
if (!vc4->primconvert)
goto fail;
- vc4->uploader = u_upload_create(pctx, 16 * 1024, 4,
+ vc4->uploader = u_upload_create(pctx, 16 * 1024,
PIPE_BIND_INDEX_BUFFER);
vc4_debug |= saved_shaderdb_flag;
16, UTIL_SLAB_SINGLETHREADED);
vctx->primconvert = util_primconvert_create(&vctx->base, rs->caps.caps.v1.prim_mask);
- vctx->uploader = u_upload_create(&vctx->base, 1024 * 1024, 256,
+ vctx->uploader = u_upload_create(&vctx->base, 1024 * 1024,
PIPE_BIND_INDEX_BUFFER);
if (!vctx->uploader)
goto fail;
This->driver_caps.user_cbufs = GET_PCAP(USER_CONSTANT_BUFFERS);
if (!This->driver_caps.user_vbufs)
- This->vertex_uploader = u_upload_create(This->pipe, 65536, 4, PIPE_BIND_VERTEX_BUFFER);
+ This->vertex_uploader = u_upload_create(This->pipe, 65536, PIPE_BIND_VERTEX_BUFFER);
if (!This->driver_caps.user_ibufs)
- This->index_uploader = u_upload_create(This->pipe, 128 * 1024, 4, PIPE_BIND_INDEX_BUFFER);
+ This->index_uploader = u_upload_create(This->pipe, 128 * 1024, PIPE_BIND_INDEX_BUFFER);
if (!This->driver_caps.user_cbufs) {
This->constbuf_alignment = GET_PCAP(CONSTANT_BUFFER_OFFSET_ALIGNMENT);
This->constbuf_uploader = u_upload_create(This->pipe, This->vs_const_size,
- This->constbuf_alignment, PIPE_BIND_CONSTANT_BUFFER);
+ PIPE_BIND_CONSTANT_BUFFER);
}
This->driver_caps.window_space_position_support = GET_PCAP(TGSI_VS_WINDOW_SPACE_POSITION);
/* Create upload manager for vertex data for glBitmap, glDrawPixels,
* glClear, etc.
*/
- st->uploader = u_upload_create(st->pipe, 65536, 4, PIPE_BIND_VERTEX_BUFFER);
+ st->uploader = u_upload_create(st->pipe, 65536, PIPE_BIND_VERTEX_BUFFER);
if (!screen->get_param(screen, PIPE_CAP_USER_INDEX_BUFFERS)) {
- st->indexbuf_uploader = u_upload_create(st->pipe, 128 * 1024, 4,
+ st->indexbuf_uploader = u_upload_create(st->pipe, 128 * 1024,
PIPE_BIND_INDEX_BUFFER);
}
- if (!screen->get_param(screen, PIPE_CAP_USER_CONSTANT_BUFFERS)) {
- unsigned alignment =
- screen->get_param(screen, PIPE_CAP_CONSTANT_BUFFER_OFFSET_ALIGNMENT);
-
- st->constbuf_uploader = u_upload_create(pipe, 128 * 1024, alignment,
+ if (!screen->get_param(screen, PIPE_CAP_USER_CONSTANT_BUFFERS))
+ st->constbuf_uploader = u_upload_create(pipe, 128 * 1024,
PIPE_BIND_CONSTANT_BUFFER);
- }
st->cso_context = cso_create_context(pipe);