flutter_soloud
flutter_soloud copied to clipboard
fix: Streaming with web sockets not working
Description
The official documentation outlines a method to use network streaming to connect to a web socket, receive chunks, and hear them in real time on a flutter app. I am building a live podcast feature and am considering soloud for it. However, if I just receive the chunks on my node js server from an input source and send them to soloud, I only hear static.
I know that the chunks are not buggy/corruputed because I am storing these chunks as a wave file on a google cloud bucket at the end of each stream, and and the produced wav file works as expected. By works, I mean that the conversation that is being recorded can be replayed in the wav file.
Steps To Reproduce
- Clone the websocket sample from here: https://github.com/alnitak/flutter_soloud/blob/main/example/lib/buffer_stream/websocket.dart
- Launch it in Android Emulator
- Connect to a node js socket that is receiving uncorrupted chunks in real time
- Connect to web socket and receive audio in the demo
Expected Behavior
Hear the conversation I record after a certain delay.
Actual Behavior
Only hear static.
Additional Context
Using flutter_soloud 3.1.7.