[][src]Enum tetra::audio::SoundState

pub enum SoundState {
    Playing,
    Paused,
    Stopped,
}

The states that playback of a SoundInstance can be in.

Variants

Playing

The sound is currently playing.

If a SoundInstance is created via Sound::play, Sound::play_with, Sound::repeat or Sound::repeat_with, it will be in this state initially.

Paused

The sound is paused. If playback is resumed, it will continue from the point where it was paused.

If a SoundInstance is created via Sound::spawn or Sound::spawn_with, it will be in this state initially.

Stopped

The sound has stopped, either manually or as a result of it reaching the end of the audio data. If playback is resumed, it will start over from the beginning of the sound.

This state will never occur while a SoundInstance is set to be repeating.

Trait Implementations

impl Clone for SoundState[src]

impl Copy for SoundState[src]

impl Debug for SoundState[src]

impl PartialEq<SoundState> for SoundState[src]

impl StructuralPartialEq for SoundState[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.