diff options
author | Ilia Mirkin <imirkin@alum.mit.edu> | 2017-06-21 23:13:20 -0400 |
---|---|---|
committer | Ilia Mirkin <imirkin@alum.mit.edu> | 2018-01-07 11:15:23 -0500 |
commit | 8eb1214755366fc34ed15a7e3dec48d4f0d65f10 (patch) | |
tree | eebd0abf02ed67a87e7ba67fbfec8dba5c3cea3c /src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c | |
parent | 70613336534fa0319a87292f40b30294b359e33a (diff) |
nvc0: add support for bindless textures on kepler+
This keeps a list of resident textures (per context), and dumps that
list into the active buffer list when submitting. We also treat bindless
texture fetches slightly differently, wrt the meaning of indirect, and
not requiring the SAMPLER file to be used.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Diffstat (limited to 'src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c')
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c index 63dccedd3e3..4cd3712203b 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c @@ -972,6 +972,11 @@ nvc0_draw_vbo(struct pipe_context *pipe, const struct pipe_draw_info *info) BCTX_REFN(nvc0->bufctx_3d, 3D_IDX, buf, RD); } + list_for_each_entry(struct nvc0_resident, resident, &nvc0->tex_head, list) { + nvc0_add_resident(nvc0->bufctx_3d, NVC0_BIND_3D_BINDLESS, resident->buf, + resident->flags); + } + nvc0_state_validate_3d(nvc0, ~0); if (nvc0->vertprog->vp.need_draw_parameters && !info->indirect) { @@ -1083,4 +1088,5 @@ cleanup: nouveau_pushbuf_bufctx(push, NULL); nouveau_bufctx_reset(nvc0->bufctx_3d, NVC0_BIND_3D_IDX); + nouveau_bufctx_reset(nvc0->bufctx_3d, NVC0_BIND_3D_BINDLESS); } |