Example #1
0
        /// <summary>
        /// Binds a vertex buffer to this command buffer
        /// </summary>
        /// <param name="binding">binding</param>
        /// <param name="buffer">buffer to bind</param>
        /// <param name="offset">offset into buffer</param>
        /// <returns>this</returns>
        public void BindVertexBuffer(uint binding, IBindableBuffer buffer, ulong offset = 0)
        {
            var bh = buffer.BindingHandle.Handle;

            offset += buffer.Offset;
            unsafe
            {
                VkCommandBuffer.vkCmdBindVertexBuffers(Handle, binding, 1, &bh, &offset);
            }
        }