aux/cso: add flag to disable vbuf
it may be known in advance that vbuf shouldn't be used, so allow users to skip this in case caps would otherwise enable it Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11071>
This commit is contained in:
parent
377936ee76
commit
3b66d70fba
|
@ -252,7 +252,8 @@ cso_create_context(struct pipe_context *pipe, unsigned flags)
|
|||
ctx->pipe = pipe;
|
||||
ctx->sample_mask = ~0;
|
||||
|
||||
cso_init_vbuf(ctx, flags);
|
||||
if (!(flags & CSO_NO_VBUF))
|
||||
cso_init_vbuf(ctx, flags);
|
||||
|
||||
/* Enable for testing: */
|
||||
if (0) cso_set_maximum_cache_size(&ctx->cache, 4);
|
||||
|
|
|
@ -44,6 +44,7 @@ struct u_vbuf;
|
|||
|
||||
#define CSO_NO_USER_VERTEX_BUFFERS (1 << 0)
|
||||
#define CSO_NO_64B_VERTEX_BUFFERS (1 << 1)
|
||||
#define CSO_NO_VBUF (1 << 2)
|
||||
|
||||
struct cso_context *cso_create_context(struct pipe_context *pipe,
|
||||
unsigned flags);
|
||||
|
|
Loading…
Reference in New Issue