#[repr(u32)]
pub enum CommandBufferUsage {
OneTimeSubmit,
MultipleSubmit,
SimultaneousUse,
}
Expand description
Usage flags to pass when creating a command buffer.
The safest option is SimultaneousUse
, but it may be slower than the other two.
Variants§
OneTimeSubmit
The command buffer can only be submitted once before being destroyed. Any further submit is forbidden. This makes it possible for the implementation to perform additional optimizations.
MultipleSubmit
The command buffer can be used multiple times, but must not execute or record more than once simultaneously. In other words, it is as if executing the command buffer borrows it mutably.
SimultaneousUse
The command buffer can be executed multiple times in parallel on different queues. If it’s a secondary command buffer, it can be recorded to multiple primary command buffers at once.
Trait Implementations§
source§impl Clone for CommandBufferUsage
impl Clone for CommandBufferUsage
source§fn clone(&self) -> CommandBufferUsage
fn clone(&self) -> CommandBufferUsage
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for CommandBufferUsage
impl Debug for CommandBufferUsage
source§impl From<CommandBufferUsage> for CommandBufferUsageFlags
impl From<CommandBufferUsage> for CommandBufferUsageFlags
source§fn from(val: CommandBufferUsage) -> Self
fn from(val: CommandBufferUsage) -> Self
Converts to this type from the input type.
source§impl Ord for CommandBufferUsage
impl Ord for CommandBufferUsage
source§fn cmp(&self, other: &CommandBufferUsage) -> Ordering
fn cmp(&self, other: &CommandBufferUsage) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<CommandBufferUsage> for CommandBufferUsage
impl PartialEq<CommandBufferUsage> for CommandBufferUsage
source§fn eq(&self, other: &CommandBufferUsage) -> bool
fn eq(&self, other: &CommandBufferUsage) -> bool
source§impl PartialOrd<CommandBufferUsage> for CommandBufferUsage
impl PartialOrd<CommandBufferUsage> for CommandBufferUsage
source§fn partial_cmp(&self, other: &CommandBufferUsage) -> Option<Ordering>
fn partial_cmp(&self, other: &CommandBufferUsage) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read more