Hi! (and sorry for the lengthy mail, tldr at the bottom)

I have a feature suggestion which, imho, would vastly simplify everything to do 
with
what song comes next.



But first, some context:

Currently mpd has a playlist with songs on it.
It decides which song to play next based on the playback mode (random or not),
which song comes after the current one and the priority each song in the 
playlist has.

This priority can be used to prefer certain songs to enable something like 
“play this song next,
then continue with the current playlist”.

Additionally there is the consume state, which controls wether songs are 
removed from the playlist
after they have been played. Afaik, there is no way to set this for individual 
songs.

These two mechanisms, priority and consume, seem to me exist mainly to provide 
means to add a track
or some tracks to be played next, even if the playlist is set to shuffle.

For me, this feels very “bolted on" after the initial playlist system was 
implemented.

It also comes with some other problems:
- Imagine a client is told to “play this song next”, so it sets the priority of 
the song to 1.
  Now the user wants another track played after the next, so the old next 
track’s priority has to 
  be changed to 2 and the second track gets priority 1.
- It limits the number of songs that can be “enqueued” for playing next to 255.
- If the tracks to be played next should not stay on the playlist, a client has 
to:
  a) remove them after they have been played or
  b) set consume to yes and reset it to no after the tracks were played



I would like to suggest an alternative to this system, which is, imho, cleaner 
and more easy to
understand and use, for developers of clients and users alike.

My suggestion is to add an additional list of tracks to be played next. For 
lack of a better name
i’ll call it the ‘queue’ (although it is not a queue in the strict sense, items 
could be reordered etc).

When mpd finishes playing a song and the number of tracks in the queue is not 
zero, it plays the
first song in the queue and removes it from the queue. When there are no tracks 
left in the queue,
mpd resumes playing the playlist where it left of.

This queue would never be played shuffled, and songs will always be consumed 
after being played.

With such a feature handled by mpd, i believe more clients would start adding 
support for “play this next”,
which would be a good thing.



I think this would be a good feature for mpd ;) (I also think it might simplify 
the codebase in some places).

What do you think?



tldr:
Add a queue of songs to play next which is preferred over the playlist. Songs 
are always removed from this list after being played and the first song is 
always chosen when determining which song to play next. Do away with the 
current priority and consume cruft.

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT 
organizations don't have a clear picture of how application performance 
affects their revenue. With AppDynamics, you get 100% visibility into your 
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
_______________________________________________
Musicpd-dev-team mailing list
Musicpd-dev-team@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/musicpd-dev-team

Reply via email to