pub struct SoundCard(/* private fields */);Expand description
A device that allows a computer or robot to play sounds.
Trait Implementations§
source§impl SoundInterface for SoundCard
impl SoundInterface for SoundCard
source§fn find_sound(&self, name: &str) -> Result<Box<[String]>>
fn find_sound(&self, name: &str) -> Result<Box<[String]>>
Returns a slice of sound effect names matching the given name. The length of the slice
is limited, so very generic names may result in a truncated list.
source§fn play_sound(&self, name: &str, volume: f64, pitch: f64) -> Result<()>where
(): DeserializeOwned + 'static,
fn play_sound(&self, name: &str, volume: f64, pitch: f64) -> Result<()>where
(): DeserializeOwned + 'static,
Plays the sound effect matching the given name at the given volume and pitch.
Auto Trait Implementations§
impl Freeze for SoundCard
impl !RefUnwindSafe for SoundCard
impl !Send for SoundCard
impl !Sync for SoundCard
impl Unpin for SoundCard
impl !UnwindSafe for SoundCard
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