Struct vulkano::sync::Semaphore
[−]
[src]
pub struct Semaphore<D = Arc<Device>> where
D: SafeDeref<Target = Device>, { /* fields omitted */ }
Used to provide synchronization between command buffers during their execution.
It is similar to a fence, except that it is purely on the GPU side. The CPU can't query a semaphore's status or wait for it to be signaled.
Methods
impl<D> Semaphore<D> where
D: SafeDeref<Target = Device>,
[src]
D: SafeDeref<Target = Device>,
fn from_pool(device: D) -> Result<Semaphore<D>, OomError>
Takes a semaphore from the vulkano-provided semaphore pool.
If the pool is empty, a new semaphore will be allocated.
Upon drop
, the semaphore is put back into the pool.
For most applications, using the pool should be preferred, in order to avoid creating new semaphores every frame.
fn alloc(device: D) -> Result<Semaphore<D>, OomError>
Builds a new semaphore.
Trait Implementations
impl<D: Debug> Debug for Semaphore<D> where
D: SafeDeref<Target = Device>,
[src]
D: SafeDeref<Target = Device>,
impl DeviceOwned for Semaphore
[src]
impl<D> VulkanObject for Semaphore<D> where
D: SafeDeref<Target = Device>,
[src]
D: SafeDeref<Target = Device>,
type Object = Semaphore
The type of the object.
fn internal_object(&self) -> Semaphore
Returns a reference to the object.
impl<D> Drop for Semaphore<D> where
D: SafeDeref<Target = Device>,
[src]
D: SafeDeref<Target = Device>,