Struct sdl2::audio::AudioQueue
source · pub struct AudioQueue<Channel: AudioFormatNum> { /* private fields */ }
Expand description
Wraps SDL_AudioDeviceID
and owns the callback data used by the audio device.
Implementations§
source§impl<'a, Channel: AudioFormatNum> AudioQueue<Channel>
impl<'a, Channel: AudioFormatNum> AudioQueue<Channel>
sourcepub fn open_queue<D: Into<Option<&'a str>>>(
a: &AudioSubsystem,
device: D,
spec: &AudioSpecDesired,
) -> Result<AudioQueue<Channel>, String>
pub fn open_queue<D: Into<Option<&'a str>>>( a: &AudioSubsystem, device: D, spec: &AudioSpecDesired, ) -> Result<AudioQueue<Channel>, String>
Opens a new audio device given the desired parameters and callback.
pub fn subsystem(&self) -> &AudioSubsystem
pub fn spec(&self) -> &AudioSpec
pub fn status(&self) -> AudioStatus
pub fn size(&self) -> u32
Auto Trait Implementations§
impl<Channel> Freeze for AudioQueue<Channel>
impl<Channel> RefUnwindSafe for AudioQueue<Channel>where
Channel: RefUnwindSafe,
impl<Channel> !Send for AudioQueue<Channel>
impl<Channel> !Sync for AudioQueue<Channel>
impl<Channel> Unpin for AudioQueue<Channel>where
Channel: Unpin,
impl<Channel> UnwindSafe for AudioQueue<Channel>where
Channel: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more