Skip to main content
100%

Gist a20e98db4b73977562c0

✓ Published0🌍 Public
Aalessioalex
Last edited Oct 24, 2012
Created on Jun 17, 2014

This example demonstrates a minimal Node.js audio player that streams an MP3 file from the filesystem and outputs it through the system’s sound device. It reads the input file using `fs.createReadStream`, decodes the audio data with the `lame` decoder, and pipes the resulting PCM stream into a `Speaker` instance. The code configures the speaker based on the audio format emitted by the decoder, enabling real-time playback. No visualization is performed; the example focuses solely on the command-line audio pipeline.

AI-generated description

Similar vizzes