moritz-weber / mucke

mucke - android music player
GNU General Public License v3.0
226 stars 12 forks source link

Smart list: top x% most/least played songs #152

Open lrq3000 opened 1 year ago

lrq3000 commented 1 year ago

Offtopic preambule

First off let me give you my praises for making this incredible offline media player for Android, it works very very well, great audio quality and incredibly intuitive UI, I particularly love smart lists, the ability to easily add filetypes (i added .mp4, it works great to read audio even from video mp4 files), and how the 3-graded favorite system works by tapping multiple times (so the idea is that you tap once first time, then when you listen again if you wish to tap again it means it's a more important favorite than others, this is deliciously simple and intuitive and useful, especially combined with the shuffle with favorites mode!).

Thank you so much for making this!

Feature request

For smart lists, one of the most useful criteria I think is the number of plays, because it requires even less user input than favorites: you can skip or replay a song while driving by tapping a button on the steering wheel, or when doing physical exercise by tapping on your headset or your smartwatch, etc.

But currently its use is limited because it's only possible to set an absolute value, which needs to be regularly modified with more use of the app (and playing more times the same songs).

Instead, to make this smart playlist based on number of plays more robust over time, i suggest to add the possibility to set a percentage instead of an absolute number of plays, eg, top 10% most/least played songs.

If the app is using a sqlite db as I suspect, it's a simple reordering of the songs by number of plays, and then extracting the top/bottom y songs, with y = floor(x/100 * total number of songs) where x is the x% of most/least played songs as the user specified.

Tricky implementation note: when extracting the bottom x%, it may include songs that were never played. In fact this can already be the case with the current absolute values inputs. An additional switch "Include never played songs?" can be added to specify whether we include or filter out never played songs.