[][src]Struct vulkano::sync::Semaphore

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]

pub fn from_pool(device: D) -> Result<Semaphore<D>, OomError>[src]

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.

pub fn alloc(device: D) -> Result<Semaphore<D>, OomError>[src]

Builds a new semaphore.

Trait Implementations

impl DeviceOwned for Semaphore[src]

impl<D> VulkanObject for Semaphore<D> where
    D: SafeDeref<Target = Device>, 
[src]

type Object = Semaphore

The type of the object.

impl<D> Drop for Semaphore<D> where
    D: SafeDeref<Target = Device>, 
[src]

impl<D: Debug> Debug for Semaphore<D> where
    D: SafeDeref<Target = Device>, 
[src]

Auto Trait Implementations

impl<D> Send for Semaphore<D> where
    D: Send

impl<D> Sync for Semaphore<D> where
    D: Sync

impl<D> Unpin for Semaphore<D> where
    D: Unpin

impl<D> UnwindSafe for Semaphore<D> where
    D: UnwindSafe

impl<D> RefUnwindSafe for Semaphore<D> where
    D: RefUnwindSafe

Blanket Implementations

impl<T> DeviceOwned for T where
    T: Deref,
    <T as Deref>::Target: DeviceOwned
[src]

impl<T> Content for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]