Overview of Realtime BPM Analyzer
mainRealtime BPM Analyzer is a lightweight (< 5KB gzipped), zero-dependency TypeScript/JavaScript library designed to detect beats-per-minute (BPM) or tempo directly in the browser. It is framework-agnostic and leverages the Web Audio API's AudioWorkletProcessor for high-performance, real-time analysis.
Key Capabilities
- Real-Time Analysis: Provides continuous updates and stable BPM detection events while audio/video is playing.
- Multiple Input Sources: Supports HTML
<audio>and<video>elements, file uploads (MP3, FLAC, WAV), microphone/getUserMediastreams, and network audio streams. - Accurate Detection: Uses amplitude threshold scanning, interval analysis, and tempo grouping to identify patterns in peak timing.
- TypeScript Support: Includes complete type definitions for type safety and IDE integration.