pub struct AudioProperties {
pub gain: Animated<f32>,
pub pan: Animated<f32>,
pub fade_in: MediaTime,
pub fade_out: MediaTime,
pub fade_shape: FadeShape,
pub muted: bool,
pub effects: Vec<AudioEffect>,
pub preserve_pitch: bool,
pub stream: Option<u32>,
pub channels: Option<Vec<u32>>,
}Expand description
Per-clip audio presentation controls.
Fields§
§gain: Animated<f32>Animated linear amplitude constrained to 0..=MAX_GAIN.
pan: Animated<f32>Animated stereo position from -1 (left) to 1 (right).
fade_in: MediaTimeFade-in duration measured from the clip’s timeline start. Non-negative.
fade_out: MediaTimeFade-out duration measured back from the clip’s timeline end. Non-negative.
fade_shape: FadeShapeCurve used by both fades.
muted: boolSilences this clip without removing it.
effects: Vec<AudioEffect>Ordered single-input effects applied before the track bus, at most MAX_CHAIN_EFFECTS.
preserve_pitch: boolKeeps the clip’s pitch when its speed is not 1 by time-stretching instead of resampling. No effect at speed 1, on loops or on freezes.
stream: Option<u32>The source’s audio stream the clip plays, counted from 0 over the file’s audio streams in container order. Absent plays the stream the host picks by default.
channels: Option<Vec<u32>>The stream’s channels the clip plays, by index. One index plays that channel as a mono source; two play a stereo pair, left then right. Absent plays every channel, folded by speaker position. At most two distinct indices.
Implementations§
Source§impl AudioProperties
impl AudioProperties
Sourcepub fn is_audible(&self) -> bool
pub fn is_audible(&self) -> bool
Returns whether this clip can contribute signal at any timestamp.