public void Begin(VkCommandBufferUsageFlag Flags) { VkCommandBufferBeginInfo CommandBufferBeginInfo = new VkCommandBufferBeginInfo(); CommandBufferBeginInfo.flags = Flags; CommandBufferBeginInfo.inheritanceInfo = null; Begin(ref CommandBufferBeginInfo); }
protected void BeginRecording(VkCommandBufferUsageFlag usage, VkCommandBufferInheritanceInfo?inheritance = null) { AssertValid(); Debug.Assert(_state == State.Allocated); unsafe { var inherit = inheritance ?? default(VkCommandBufferInheritanceInfo); var info = new VkCommandBufferBeginInfo() { SType = VkStructureType.CommandBufferBeginInfo, PNext = IntPtr.Zero, Flags = usage, PInheritanceInfo = inheritance.HasValue ? &inherit : (VkCommandBufferInheritanceInfo *)0 }; Handle.BeginCommandBuffer(&info); _state = State.Building; } }
public CommandBufferRecorder RecordCommands(VkCommandBufferUsageFlag usage, VkCommandBufferInheritanceInfo?inheritance = null) { BeginRecording(usage, inheritance); return(new CommandBufferRecorder(this)); }