pub struct SsirResult {
pub segments: Vec<RirSegment>,
pub mixing_time_samples: usize,
pub sample_rate: f64,
}Expand description
Result of SSIR analysis on a room impulse response.
Fields§
§segments: Vec<RirSegment>Ordered sequence of segments covering the early RIR. First segment is always the direct sound. Segments are consecutive: segment[i].end_sample == segment[i+1].onset_sample
mixing_time_samples: usizeEstimated mixing time in samples (boundary between early reflections and reverberant tail)
sample_rate: f64Sample rate used for analysis
Implementations§
Source§impl SsirResult
impl SsirResult
Sourcepub fn num_events(&self) -> usize
pub fn num_events(&self) -> usize
Number of detected sound events (direct sound + early reflections)
Sourcepub fn num_reflections(&self) -> usize
pub fn num_reflections(&self) -> usize
Number of early reflections (excludes direct sound)
Sourcepub fn mixing_time_ms(&self) -> f64
pub fn mixing_time_ms(&self) -> f64
Mixing time in milliseconds
Sourcepub fn reflections(&self) -> impl Iterator<Item = &RirSegment>
pub fn reflections(&self) -> impl Iterator<Item = &RirSegment>
Iterator over only the early reflection segments (excludes direct sound)
Sourcepub fn direct_sound(&self) -> Option<&RirSegment>
pub fn direct_sound(&self) -> Option<&RirSegment>
The direct sound segment, if detected
Trait Implementations§
Source§impl Clone for SsirResult
impl Clone for SsirResult
Source§fn clone(&self) -> SsirResult
fn clone(&self) -> SsirResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SsirResult
impl RefUnwindSafe for SsirResult
impl Send for SsirResult
impl Sync for SsirResult
impl Unpin for SsirResult
impl UnsafeUnpin for SsirResult
impl UnwindSafe for SsirResult
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more