-
Notifications
You must be signed in to change notification settings - Fork 18
Play songs one after another #25
Comments
Hi @UdithaIshan ! Not the best solution, but you may use This library is a very minimal implementation over miniaudio, even streams aren't added yet. You are supposed to make your own playback logic in dart. Thankyou. |
@alexmercerind I also thought about that, but then we can't use the Cheers 🍻 |
@UdithaIshan, ah I see. I'll try to do something regarding this in future. |
Hi there @UdithaIshan! I know I'm very late to reply on this. Now, one can listen to playback events, which will help me add things like playlists, looping etc. Windows implementation coming real soon. Thanks |
The stream has way to much stuff going through it, in the example try slowly dragging the slider to forward the song, its going to take a VERY long time for eventloop to catch up. If you just click anywhere on slider that would obviously work. |
@syleishere And, delay is caused by miniaudio. As one is not supposed to not change position every millisecond one drags, I haven't implemented any such condition to just ignore too many subsequent calls. So, just click on the slider somewhere for now. |
So I ran song looping for over 24 hours on my windows machine without any issues. I found the error seems to be IsCompleted gets set before it should, requiring a call back to eventloop so whatever needs finishing finishes before another song can be started, so I found just tossing another song back in eventloop to start with even a 1 millisecond duration will allow one song to be played after the other with no issues: Example that has worked for me: class FirstPage2 extends State { |
I guess my only suggestion at this point would be if you are going to do a queuing system for songs, to play the songs in a separate isolate so that GUI is not affected for anything other than communicating with the isolate to play a song. Also so it can utilize another core on the CPU for playing songs :) I think would be a good idea to do an implementation in pure dart, would keep code clean and maintainable, then on flutter side just show people how to communicate with the isolate :) |
Hi there @UdithaIshan ! Thanks for supporting this project. Now libVLC based alternative to this project is live: It has (in addition to this project):
Other features are in the list. Please use that plugin now instead of this one. Hope you liked my work. |
How can I play multiple songs one after another using this? @alexmercerind
The text was updated successfully, but these errors were encountered: