#[non_exhaustive]pub struct AdjustConfig { /* private fields */ }Expand description
Search window and cut preferences for adjust.
Implementations§
Source§impl AdjustConfig
impl AdjustConfig
Sourcepub fn new(window: Duration) -> Self
pub fn new(window: Duration) -> Self
Searches within window of each point, using default weights and the quietest placement.
A zero window snaps each point to the nearest frame boundary when no candidate is exact.
Sourcepub fn weights(self, weights: Weights) -> Result<Self, ConfigError>
pub fn weights(self, weights: Weights) -> Result<Self, ConfigError>
Sets the cut cost weights. Length weights are unused; distance from the point always has weight one. The fixed per-cut cost is identical for all choices of one point.
§Errors
ConfigError::InvalidWeights for invalid weights, as with crate::PlanConfig::weights.
Sourcepub fn placement(self, placement: Placement) -> Result<Self, ConfigError>
pub fn placement(self, placement: Placement) -> Result<Self, ConfigError>
Sets the representative cut position inside each silence.
§Errors
ConfigError::InvalidRatio if a ratio is outside 0.0..=1.0.
Trait Implementations§
Source§impl Clone for AdjustConfig
impl Clone for AdjustConfig
Source§impl Debug for AdjustConfig
impl Debug for AdjustConfig
Source§impl PartialEq for AdjustConfig
impl PartialEq for AdjustConfig
impl StructuralPartialEq for AdjustConfig
Auto Trait Implementations§
impl Freeze for AdjustConfig
impl RefUnwindSafe for AdjustConfig
impl Send for AdjustConfig
impl Sync for AdjustConfig
impl Unpin for AdjustConfig
impl UnsafeUnpin for AdjustConfig
impl UnwindSafe for AdjustConfig
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