[−][src]Struct nobs_vulkanism_headless::cmd::Stream
Wrapps a vulkan command buffer
The stream is basically a builder pattern for all vulkan functions related to vk::Cmd*
.
For every command in commands we can use push to enqueue it to the command stream.
When we are done building the command stream, we push it into a batch (BatchSubmit, AutoBatch, Frame). The batch can then submit all streams with one queue submit call. This is useful, since queue submit calls are very overhead heavy.
Fields
buffer: CommandBuffer
Methods
impl Stream
[src]
pub fn new(streams: Arc<Mutex<StreamCache>>) -> Result<Self, Error>
[src]
Is only called by Pool
pub fn begin(self) -> Result<Self, Error>
[src]
Is implicitly called in Pool::begin_stream
pub fn push<T: StreamPush>(self, o: &T) -> Self
[src]
Pushes a command into a stream.
Any struct implementing the StreamPush trait can be pushed into the stream. This can be used to build more complex commands from many primitive ones and be able to push them with one call.
pub fn waive(self)
[src]
Returns the stream to the pool.
This breaks up configuring the stream and returns it to the pool. No vulkan commands are submitted, the command buffer can be reused again.
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,