Struct vulkano::buffer::sys::BufferCreateInfo
source · pub struct BufferCreateInfo {
pub flags: BufferCreateFlags,
pub sharing: Sharing<SmallVec<[u32; 4]>>,
pub size: DeviceSize,
pub usage: BufferUsage,
pub external_memory_handle_types: ExternalMemoryHandleTypes,
pub _ne: NonExhaustive,
}
Expand description
Parameters to create a new Buffer
.
Fields§
§flags: BufferCreateFlags
Additional properties of the buffer.
The default value is empty.
sharing: Sharing<SmallVec<[u32; 4]>>
Whether the buffer can be shared across multiple queues, or is limited to a single queue.
The default value is Sharing::Exclusive
.
size: DeviceSize
The size in bytes of the buffer.
When using the Buffer
constructors, you must leave this at 0
. They fill this field
based on the data type of the contents and the other parameters you provide, and then pass
this create-info to RawBuffer::new
. You must override the default when constructing
RawBuffer
directly.
The default value is 0
.
usage: BufferUsage
How the buffer is going to be used.
The default value is BufferUsage::empty()
, which must be overridden.
external_memory_handle_types: ExternalMemoryHandleTypes
The external memory handle types that are going to be used with the buffer.
If this value is not empty, then the device API version must be at least 1.1, or the
khr_external_memory
extension must be enabled on the device.
The default value is ExternalMemoryHandleTypes::empty()
.
_ne: NonExhaustive
Trait Implementations§
source§impl Clone for BufferCreateInfo
impl Clone for BufferCreateInfo
source§fn clone(&self) -> BufferCreateInfo
fn clone(&self) -> BufferCreateInfo
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more