nvk: Bind texture and sampler header pools for 3D
No idea if this has to be done separately for 3D vs. compute but it shouldn't hurt anything to do it for both. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
This commit is contained in:
committed by
Marge Bot
parent
c25f0c1dbe
commit
17ab445930
@@ -170,6 +170,7 @@ void
|
||||
nvk_cmd_buffer_begin_graphics(struct nvk_cmd_buffer *cmd,
|
||||
const VkCommandBufferBeginInfo *pBeginInfo)
|
||||
{
|
||||
struct nvk_device *dev = nvk_cmd_buffer_device(cmd);
|
||||
struct nouveau_ws_push *p = cmd->push;
|
||||
|
||||
P_MTHD(p, NV9097, SET_OBJECT);
|
||||
@@ -214,6 +215,20 @@ nvk_cmd_buffer_begin_graphics(struct nvk_cmd_buffer *cmd,
|
||||
|
||||
P_IMMD(p, NV9097, SET_SHADER_LOCAL_MEMORY_WINDOW, 0xff000000); /* TODO */
|
||||
|
||||
nvk_push_descriptor_table_ref(p, &dev->samplers);
|
||||
uint64_t tsp_addr = nvk_descriptor_table_base_address(&dev->samplers);
|
||||
P_MTHD(p, NV9097, SET_TEX_SAMPLER_POOL_A);
|
||||
P_NV9097_SET_TEX_SAMPLER_POOL_A(p, tsp_addr >> 32);
|
||||
P_NV9097_SET_TEX_SAMPLER_POOL_B(p, tsp_addr);
|
||||
P_NV9097_SET_TEX_SAMPLER_POOL_C(p, dev->samplers.alloc - 1);
|
||||
|
||||
nvk_push_descriptor_table_ref(p, &dev->images);
|
||||
uint64_t thp_addr = nvk_descriptor_table_base_address(&dev->images);
|
||||
P_MTHD(p, NV9097, SET_TEX_HEADER_POOL_A);
|
||||
P_NV9097_SET_TEX_HEADER_POOL_A(p, thp_addr >> 32);
|
||||
P_NV9097_SET_TEX_HEADER_POOL_B(p, thp_addr & 0xffffffff);
|
||||
P_NV9097_SET_TEX_HEADER_POOL_C(p, dev->images.alloc - 1);
|
||||
|
||||
/* TODO: TIC */
|
||||
/* TODO: TSC */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user