pub struct Audio {
pub id: Option<String>,
pub path: String,
pub trim_start: Option<f64>,
pub trim_end: Option<f64>,
pub loop: bool,
pub volume: Option<f32>,
pub fade_in: Option<f64>,
pub fade_out: Option<f64>,
pub duck_under: Option<String>,
pub duck_depth_db: Option<f32>,
pub at: Option<f64>,
pub duration: Option<f64>,
}Expand description
A sound file.
Fields§
§id: Option<String>The node’s name, for other nodes to refer to.
path: StringThe file.
trim_start: Option<f64>Where in the file it starts, in seconds.
trim_end: Option<f64>Where in the file it ends, in seconds. Default: its end.
loop: boolPlays the file again from its start while the node lasts.
volume: Option<f32>Linear gain. Default 1.
fade_in: Option<f64>Seconds of fade in.
fade_out: Option<f64>Seconds of fade out.
duck_under: Option<String>The id of a node (or body) whose sound this ducks under.
duck_depth_db: Option<f32>How far ducking lowers it, in dB (negative). Default -12.
at: Option<f64>Seconds from the parent’s start (an overlay’s: the video’s). Ignored in a sequence.
duration: Option<f64>Length in seconds. Default: the node’s own length, else what its parent gives it.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Audio
impl<'de> Deserialize<'de> for Audio
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Audio
Auto Trait Implementations§
impl Freeze for Audio
impl RefUnwindSafe for Audio
impl Send for Audio
impl Sync for Audio
impl Unpin for Audio
impl UnsafeUnpin for Audio
impl UnwindSafe for Audio
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