public static void SetTransientIndexBuffer(TransientIndexBuffer index_buffer, int first_index, int num_indices) { unsafe { Bgfx.set_transient_index_buffer(&index_buffer, (uint)first_index, (uint)num_indices); } }
public static TransientIndexBuffer Create(Span <ushort> indices) { var transient_idx_buffer = new TransientIndexBuffer(indices.Length); var data_size = (uint)(indices.Length * sizeof(ushort)); Unsafe.CopyBlock((void *)transient_idx_buffer.data, Unsafe.AsPointer(ref indices[0]), data_size); return(transient_idx_buffer); }
public static void AllocTransientIndexBuffer(out TransientIndexBuffer buffer, int num_indices) { Bgfx.alloc_transient_index_buffer(out buffer, (uint)num_indices); }