openmixer — generated API reference
    Preparing search index...

    Function reduceSpectrumBands

    • Reduce an already-banded reading to nOut bands over the same range.

      The second half of a two-step reduction, and it exists because the two steps happen in different processes: the desk bands once, at whatever resolution the subscriber asked for on a stream it opened before any panel existed, and a panel then narrows to the bar count its current width supports. Re-banding from raw bins would be better and is not available — the bins are the thing that did not cross the wire.

      Bands in, bands out, same tiling: each output band covers a contiguous run of inputs, its db is their ENERGY mean (the same RMS-in-dB the first step computed, so two steps read as one) and its peakDb the loudest of them. An output band that lands between two inputs takes the nearer, so a narrow panel still draws rather than reading as silence.

      Asking for as many or more than there are is the identity: this only ever coarsens, because detail the desk did not send cannot be invented here.

      Parameters

      Returns readonly SpectrumBand[]