foo-webview-sdk
    Preparing search index...

    Interface AudioGetSpectrumParams

    Parameters for audio.getSpectrum. Compute one spectrum frame on demand. At least one spectrum subscription must exist.

    interface AudioGetSpectrumParams {
        bands?: number;
        channels?: "mix" | "stereo";
        maxFrequency?: number;
        minFrequency?: number;
        output?: "bands" | "bins";
        scale?: "weighted" | "db";
        subscriptionId?: string;
    }
    Index
    bands?: number

    Used without subscriptionId. 0 takes the largest band count among all subscriptions; the value is capped at fftSize / 2.

    0
    
    channels?: "mix" | "stereo"

    Without subscriptionId only mix is accepted.

    "mix"
    
    maxFrequency?: number

    Used without subscriptionId; as in subscribeSpectrum.

    minFrequency?: number

    Used without subscriptionId; as in subscribeSpectrum.

    20
    
    output?: "bands" | "bins"

    Without subscriptionId only bands is accepted: the FFT size then follows the other subscriptions, so bin output needs a subscription of its own.

    "bands"
    
    scale?: "weighted" | "db"

    Used without subscriptionId; as in subscribeSpectrum.

    "weighted"
    
    subscriptionId?: string

    Compute the frame with this subscription's parameters, bin output included; the other parameters are then ignored. An unknown id fails with NOT_FOUND.