Type alias SpectrogramPluginOptions

SpectrogramPluginOptions: {
    alpha?: number;
    colorMap?: number[][];
    container: string | HTMLElement;
    fftSamples?: number;
    frequencyMax?: number;
    frequencyMin?: number;
    height?: number;
    labels?: boolean;
    labelsBackground?: string;
    labelsColor?: string;
    labelsHzColor?: string;
    noverlap?: number;
    windowFunc?: "bartlett" | "bartlettHann" | "blackman" | "cosine" | "gauss" | "hamming" | "hann" | "lanczoz" | "rectangular" | "triangular";
}

Type declaration

  • Optional alpha?: number

    Some window functions have this extra value. (Between 0 and 1)

  • Optional colorMap?: number[][]

    A 256 long array of 4-element arrays. Each entry should contain a float between 0 and 1 and specify r, g, b, and alpha. Each entry should contain a float between 0 and 1 and specify r, g, b, and alpha.

  • container: string | HTMLElement

    Selector of element or element in which to render

  • Optional fftSamples?: number

    Number of samples to fetch to FFT. Must be a power of 2.

  • Optional frequencyMax?: number

    Max frequency to scale spectrogram. Set this to samplerate/2 to draw whole range of spectrogram.

  • Optional frequencyMin?: number

    Min frequency to scale spectrogram.

  • Optional height?: number

    Height of the spectrogram view in CSS pixels

  • Optional labels?: boolean

    Set to true to display frequency labels.

  • Optional labelsBackground?: string
  • Optional labelsColor?: string
  • Optional labelsHzColor?: string
  • Optional noverlap?: number

    Size of the overlapping window. Must be < fftSamples. Auto deduced from canvas size by default.

  • Optional windowFunc?: "bartlett" | "bartlettHann" | "blackman" | "cosine" | "gauss" | "hamming" | "hann" | "lanczoz" | "rectangular" | "triangular"

    The window function to be used.

Generated using TypeDoc