MCPcopy Create free account
hub / github.com/cleggacus/bhusie / create_buffer

Method create_buffer

src/renderer/array_buffer.rs:81–89  ·  view source on GitHub ↗
(&self, device: &wgpu::Device)

Source from the content-addressed store, hash-verified

79 }
80
81 pub fn create_buffer(&self, device: &wgpu::Device) -> wgpu::Buffer {
82 device.create_buffer_init(
83 &wgpu::util::BufferInitDescriptor {
84 label: None,
85 contents: bytemuck::cast_slice(&[self.entity_uniforms]),
86 usage: wgpu::BufferUsages::STORAGE | wgpu::BufferUsages::COPY_DST,
87 }
88 )
89 }
90}
91
92impl<const MAX_ENTITIES: usize, T, U> Default for ArrayBuffer<MAX_ENTITIES, T, U>

Callers 2

newMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected