ConfigTransient configures the pool for transient command buffers, which are best used for random functions, such as memory copying. Use EndSubmitWaitFree logic.
(dv *Device)
| 21 | // which are best used for random functions, such as memory copying. |
| 22 | // Use EndSubmitWaitFree logic. |
| 23 | func (cp *CmdPool) ConfigTransient(dv *Device) { |
| 24 | var cmdPool vk.CommandPool |
| 25 | ret := vk.CreateCommandPool(dv.Device, &vk.CommandPoolCreateInfo{ |
| 26 | SType: vk.StructureTypeCommandPoolCreateInfo, |
| 27 | QueueFamilyIndex: dv.QueueIndex, |
| 28 | Flags: vk.CommandPoolCreateFlags(vk.CommandPoolCreateTransientBit), |
| 29 | }, nil, &cmdPool) |
| 30 | IfPanic(NewError(ret)) |
| 31 | cp.Pool = cmdPool |
| 32 | } |
| 33 | |
| 34 | // ConfigResettable configures the pool for persistent, |
| 35 | // resettable command buffers, used for rendering commands. |