Table of Contents
- About the Project
- Dev Environment
About The Project
The project utilizes electrons desktopCapturer to capture raw audio. The stream of raw audio is captured in the format of 32 bit float.
The server expects a stream of 16 bit signed integer. Hence the conversion before sending the stream to the server.
The stream is sent to the backend by IPC. Early versions of the software sent the stream via socket.io but the use of another package seemed redundant. I noticed no performance changes going from sockets to IPC.
The stream of 16 bit signed integers is encoded to mp3 with LAME. I had issues with the sample rate being inconsistent on different computers leading to a high/low pitched final result. To solve this I implemented an option to change the sample rate in the client.
The stream is now in the format of mp3 and ready for broadcast. The stream is linked to an endpoint served by express, the url of the endpoint is then sent by node-sonos to selected devices.
To get a local copy up and running follow these simple steps.
- Clone the repo
git clone https://github.com/filahf/budgie-stream.git
- Install NPM packages
cd budgie-stream/ yarn install
Node module was built with the wrong versionRun electron rebuild
Or if you're on Windows:
- Download system corresponding package
- Make sure to allow Budgie Stream through the firewall
- Select devices and hit play!
Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature)
- Commit your Changes (
git commit -m 'Add some AmazingFeature')
- Push to the Branch (
git push origin feature/AmazingFeature)
- Open a Pull Request
Distributed under the MIT License. See
LICENSE for more information.
Feel free to contact me if you have any questions.
Filip Åhfelt - filipahfelt.se
Project Link: https://github.com/filahf/budgie-stream