pub struct MonitorMinMax {
    sig_idx: usize,
    buf: [(f32, f32); 160],
    buf_write_ptr: usize,
    cur_min_max: (f32, f32, usize),
}
Expand description

Implements the logic for min/maxing a single signal channel/line.

Fields

sig_idx: usize

Index of the signal in the MonitorBuf

buf: [(f32, f32); 160]

A ring buffer of min/max samples, written to by buf_write_ptr.

buf_write_ptr: usize

The pointer/index into buf to the next update to write.

cur_min_max: (f32, f32, usize)

Holds the currently accumulated min/max values and the length of so far processed audio rate samples. Once MONITOR_INPUT_LEN_PER_SAMPLE is reached, this will be written into buf.

Implementations

Processes a monitoring buffer received from the Backend. It returns true when a new data point was calculated.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.