Mark the smoother's style field pub
This is useful when using the smoother as a simple amplitude envelope.
This commit is contained in:
parent
d610230aca
commit
2bb698a8f1
1 changed files with 1 additions and 8 deletions
|
@ -36,7 +36,7 @@ pub enum SmoothingStyle {
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub struct Smoother<T> {
|
pub struct Smoother<T> {
|
||||||
/// The kind of snoothing that needs to be applied, if any.
|
/// The kind of snoothing that needs to be applied, if any.
|
||||||
style: SmoothingStyle,
|
pub style: SmoothingStyle,
|
||||||
/// The number of steps of smoothing left to take.
|
/// The number of steps of smoothing left to take.
|
||||||
///
|
///
|
||||||
// This is a signed integer because we can skip multiple steps, which would otherwise make it
|
// This is a signed integer because we can skip multiple steps, which would otherwise make it
|
||||||
|
@ -119,13 +119,6 @@ impl<T: Smoothable> Smoother<T> {
|
||||||
Default::default()
|
Default::default()
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Get the smoother's style. This is useful when a per-voice smoother wants to use the same
|
|
||||||
/// style as a parameter's global smoother.
|
|
||||||
#[inline]
|
|
||||||
pub fn style(&self) -> SmoothingStyle {
|
|
||||||
self.style
|
|
||||||
}
|
|
||||||
|
|
||||||
/// The number of steps left until calling [`next()`][Self::next()] will stop yielding new
|
/// The number of steps left until calling [`next()`][Self::next()] will stop yielding new
|
||||||
/// values.
|
/// values.
|
||||||
#[inline]
|
#[inline]
|
||||||
|
|
Loading…
Add table
Reference in a new issue