mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 23:32:09 +00:00
Fix incorrect init of command buffer set
This commit is contained in:
parent
4b152a4492
commit
ce72135e70
1 changed files with 5 additions and 2 deletions
|
@ -137,12 +137,15 @@ QFV_AllocateCommandBuffers (qfv_cmdpool_t *pool, int secondary, int count)
|
|||
cmdbufferset->buffers = (qfv_cmdbuffer_t **) (cmdbufferset + 1);
|
||||
cmdbufferset->vkBuffers = (VkCommandBuffer *) (cmdbufferset->buffers
|
||||
+ count);
|
||||
qfv_cmdbuffer_t *buffer = (qfv_cmdbuffer_t *) (cmdbufferset->vkBuffers
|
||||
+ count);
|
||||
cmdbufferset->cmdpool = pool->cmdpool;
|
||||
cmdbufferset->numBuffers = count;
|
||||
dfunc->vkAllocateCommandBuffers (dev, &allocInfo, cmdbufferset->vkBuffers);
|
||||
for (int i = 0; i < count; i++) {
|
||||
cmdbufferset->buffers[i]->device = device;
|
||||
cmdbufferset->buffers[i]->buffer = &cmdbufferset->vkBuffers[i];
|
||||
buffer->device = device;
|
||||
buffer->buffer = &cmdbufferset->vkBuffers[i];
|
||||
cmdbufferset->buffers[i] = buffer++;
|
||||
}
|
||||
return cmdbufferset;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue