#[repr(C)]pub struct Sound {
pub stream: AudioStream,
pub frame_count: c_uint,
}
Fields§
§stream: AudioStream
§frame_count: c_uint
Implementations§
Source§impl Sound
impl Sound
pub fn load(path: impl AsRef<Path>) -> Self
pub fn load_from_wave(wave: &Wave) -> Self
pub fn is_ready(&self) -> bool
pub fn play(&self)
pub fn stop(&self)
pub fn pause(&self)
pub fn resume(&self)
pub fn is_playing(&self) -> bool
pub fn set_voume(&self, volume: f32)
pub fn set_pitch(&self, pitch: f32)
pub fn set_pan(&self, pan: f32)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Sound
impl RefUnwindSafe for Sound
impl !Send for Sound
impl !Sync for Sound
impl Unpin for Sound
impl UnwindSafe for Sound
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