GitHub

Source

useMultibandTrackVolume

Note

This feature is experimental and may change or be removed based on developer feedback and real-world usage.

Hook for tracking the volume of an audio track across multiple frequency bands using the Web Audio API.

Import

import { useMultibandTrackVolume } from "@livekit/components-react";

Properties

options.analyserOptionsAnalyserOptionsOptional
options.bandsnumberOptional
options.hiPassnumberOptional

cut off of frequency bins on the higher end Note: this is not a frequency measure, but in relation to analyserOptions.fftSize,

options.loPassnumberOptional

cut off of frequency bins on the lower end Note: this is not a frequency measure, but in relation to analyserOptions.fftSize,

options.updateIntervalnumberOptional

update should run every x ms

trackOrTrackReferenceLocalAudioTrack | RemoteAudioTrack | TrackReferenceOrPlaceholderOptional

Returns

number[]