pub struct MainTrackHandle { /* private fields */ }Expand description
Controls the main mixer track.
Implementations§
Source§impl MainTrackHandle
impl MainTrackHandle
Sourcepub fn play<D: SoundData>(
&mut self,
sound_data: D,
) -> Result<D::Handle, PlaySoundError<D::Error>>
pub fn play<D: SoundData>( &mut self, sound_data: D, ) -> Result<D::Handle, PlaySoundError<D::Error>>
Plays a sound.
Sourcepub fn set_volume(&mut self, volume: impl Into<Value<Decibels>>, tween: Tween)
pub fn set_volume(&mut self, volume: impl Into<Value<Decibels>>, tween: Tween)
Sets the (post-effects) volume of the mixer track.
Sourcepub fn sound_capacity(&self) -> usize
pub fn sound_capacity(&self) -> usize
Returns the maximum number of sounds that can play simultaneously on this track.
Sourcepub fn num_sounds(&self) -> usize
pub fn num_sounds(&self) -> usize
Returns the number of sounds currently playing on this track.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for MainTrackHandle
impl !RefUnwindSafe for MainTrackHandle
impl Send for MainTrackHandle
impl Sync for MainTrackHandle
impl Unpin for MainTrackHandle
impl UnsafeUnpin for MainTrackHandle
impl !UnwindSafe for MainTrackHandle
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