bluefireteam / audioplayers

A Flutter package to play multiple audio files simultaneously (Android/iOS/web/Linux/Windows/macOS)
https://pub.dartlang.org/packages/audioplayers
MIT License
2.01k stars 845 forks source link

playlists #1781

Open syleishere opened 7 months ago

syleishere commented 7 months ago

Checklist

Use case / Problem

In browsers, without a playlist, if you switch tabs, minimize browser etc, the current song playing will not switch to next song till tab is refocused. It is possible to keep replaying same current song over and over again only, which is horrible.

Proposal / Solution

Add a playlist option, where users can add all their current songs to it, that way when browser is out of focus, people can still play all their songs.

Example Code

Example Code ```dart void main() { } ```

Affected platforms

web

Platform details

No response

Audio Files/URLs/Sources

No response

Mockups

No response

Related issues / more information

No response

Working on PR

no way

syleishere commented 7 months ago

This mainly affects all browsers except firefox from my testing. Even enabling site permissions in chrome for music did nothing.

syleishere commented 7 months ago

I think this could also serve as a great test case for benchmarking audioplayers. I am no DJ but when I researched how they work, with playlist support, they would need 3 separate playlist streams. 1 for left side, 1 for right side tracks, and one in middle for adding custom content between playlist streams ie: while phasing out song1 from playlist1 to song2 on playlist2, use playlist 3 to say something like "Owww Yeah..."

For benchmarking, could try adding 20,000 songs off your NAS to it, see how it holds under pressure type thing. I actually have found very few software that could do it well except winamp. I think all the others might be doing something stupid like preprocessing meta data while adding them, instead of doing it post processing.

For anyone willing to work on this, I have a free gift, 70GB uncompressed folder collection for you to use in your development, you can toss on your ZFS NAS etc, that way can hopefully test over Samba for performance from your windows 11 etc machine. I would be testing it from Flet app wrapping audioplayers in their main distribution, a contribution to python community. Congratulations for being selected by Flet as their main audioplayer over the many others on pub.dev.

My appreciation of your time and consideration ....