mickeyf.docs
    Preparing search index...

    Snapshot of audio analysis state exposed to the rest of the app.

    Consumers typically treat these values as “latest known” readings that are refreshed while playback is running.

    type AudioState = {
        beat: BeatState;
        clarity: number;
        durationSec: number;
        hasAudio: boolean;
        pitchHz: number;
        playing: boolean;
        volumeDb: number;
    }
    Index

    Properties

    beat: BeatState

    Simple beat detection output for the current frame.

    clarity: number

    Pitch confidence in $[0, 1]$ as returned by pitchy.

    durationSec: number

    Track duration in seconds (from the underlying HTMLAudioElement).

    hasAudio: boolean

    Whether an audio source has been loaded (file selected and graph initialized).

    pitchHz: number

    Detected fundamental frequency in Hz. 0 when unknown/unavailable.

    playing: boolean

    Whether playback is currently active.

    volumeDb: number

    Peak-derived volume estimate in dB. -Infinity represents silence/no signal.