Allegro is a comprehensive showcase application demonstrating the power of the
realtime-bpm-analyzerlibrary. This Next.js application provides professional-grade BPM analysis tools for music producers, DJs, and audio enthusiasts.
π Live Demo: allegro-project.com
- π File Analysis - Upload and analyze BPM from audio files (MP3, WAV, FLAC)
- π€ Real-time Microphone - Live BPM detection from your microphone input
- π» Audio Stream Analysis - Analyze BPM from online radio streams and URLs
- π Visual Analytics - Real-time audio visualization and BPM tracking
- π± Mobile Responsive - Fully optimized for mobile devices with touch-friendly UI
- π¨ Modern UI - Beautiful glassmorphic design with smooth animations
This application showcases the capabilities of the realtime-bpm-analyzer library:
npm install realtime-bpm-analyzer- β‘ Real-time processing - Analyze BPM as audio streams
- π― High accuracy - Advanced algorithms for precise BPM detection
- π Multiple input sources - Files, streams, microphone, audio nodes
- π Web Audio API - Leverages modern browser capabilities
- π¦ Zero dependencies - Lightweight and performant
- ποΈ Configurable - Customizable analysis parameters
import { createRealtimeBpmAnalyzer } from 'realtime-bpm-analyzer';
// Create audio context and processor
const audioContext = new AudioContext();
const analyzer = await createRealtimeBpmAnalyzer(audioContext);
// Connect to audio source
source.connect(analyzer);
// Listen for BPM events with typed listeners
analyzer.on('bpm', (data) => {
console.log('Current BPM:', data.bpm[0].tempo);
});
analyzer.on('bpmStable', (data) => {
console.log('Stable BPM detected:', data.bpm[0].tempo);
});- Node.js 22+
- npm or yarn or pnpm
-
Clone the repository
git clone https://github.com/dlepaux/allegro.git cd allegro -
Install dependencies
npm install # or yarn install # or pnpm install
-
Start development server
npm run dev # or yarn dev # or pnpm dev
-
Open your browser
http://localhost:3000
- Track Analysis - Quickly determine BPM of samples and loops
- Tempo Matching - Find tracks with similar BPMs for mashups
- Live Recording - Real-time BPM monitoring during performances
- Beatmatching - Precise BPM detection for seamless mixing
- Set Preparation - Batch analyze music libraries
- Live Analysis - Real-time BPM detection during sets
- Integration Examples - See how to implement realtime-bpm-analyzer
- Best Practices - Learn optimal Web Audio API usage patterns
- Performance Optimization - Understand efficient audio processing
We welcome contributions! This project serves as both a showcase for realtime-bpm-analyzer and a testing ground for new features.
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Follow the existing code style (ESLint + TypeScript)
- Test thoroughly across different audio sources
- Update documentation if needed
- Submit a pull request
- π¨ UI/UX improvements - Enhance the user interface
- π New visualizations - Create audio analysis charts
- π§ Performance optimizations - Improve audio processing
- π± Mobile enhancements - Better touch interactions
- π Accessibility - Improve screen reader support
- π§ͺ Testing - Add unit and integration tests
- π¦ NPM Package: realtime-bpm-analyzer
- π GitHub Repository: dlepaux/realtime-bpm-analyzer
- π API Documentation: Available in the package README
// File analysis - Offline/synchronous analysis
import { analyzeFullBuffer } from 'realtime-bpm-analyzer';
const tempos = await analyzeFullBuffer(audioBuffer);
console.log('BPM:', tempos[0].tempo);
// Custom filtering for better bass detection
import { getBiquadFilter } from 'realtime-bpm-analyzer';
const filter = getBiquadFilter(audioContext);
source.connect(filter).connect(analyzer);
// Real-time stream processing with typed events
analyzer.on('bpm', (data) => {
console.log('Analyzing...', data.bpm[0].tempo);
});
analyzer.on('bpmStable', (data) => {
console.log('Stable BPM detected:', data.bpm[0].tempo);
console.log('Confidence:', data.bpm[0].count);
});
// Continuous analysis for streams (auto-resets)
const streamAnalyzer = await createRealtimeBpmAnalyzer(audioContext, {
continuousAnalysis: true,
stabilizationTime: 20000 // Reset every 20 seconds
});
streamAnalyzer.on('analyzerReset', () => {
console.log('Analyzer reset - starting fresh analysis');
});This project is licensed under the Apache License - see the LICENSE file for details.
- realtime-bpm-analyzer - The core BPM detection engine
- Web Audio API - Modern browser audio processing capabilities
- Next.js Team - Amazing React framework
- Tailwind CSS - Utility-first CSS framework
π Visit Live Demo β’ π¦ NPM Package β’ π GitHub
Built with β€οΈ for the audio development community