pub struct SoundSpec<'a> {
pub name: &'static str,
pub bytes: &'a [u8],
pub base_volume: f32,
pub bus: AudioBus,
}Expand description
One entry in a SoundBank: where the bytes come from and how the cue
should sit in the mix before per-call parameters are applied.
Fields§
§name: &'static strA stable name used for lookups and error reporting.
bytes: &'a [u8]The encoded clip, typically an include_bytes! WAV.
base_volume: f32The cue’s own level, so a loud explosion and a quiet tick can share one call site without per-call bookkeeping.
bus: AudioBusThe bus the cue plays on.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for SoundSpec<'a>
impl<'a> RefUnwindSafe for SoundSpec<'a>
impl<'a> Send for SoundSpec<'a>
impl<'a> Sync for SoundSpec<'a>
impl<'a> Unpin for SoundSpec<'a>
impl<'a> UnsafeUnpin for SoundSpec<'a>
impl<'a> UnwindSafe for SoundSpec<'a>
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