[vlc-devel] playlist: flat / tree separation

Rémi Denis-Courmont remi at remlab.net
Fri Aug 21 18:19:29 CEST 2009


Le vendredi 21 août 2009 15:43:07 Jakob Leben, vous avez écrit :
> I remember someone said that the separation between flat and tree playlist
> remained because some modules were not compatible with tree playlist. I
> think keeping this separation complicates many algorithms concerning the
> playlist and I see it as a big step forward to remove this separation. Does
> anybody know of a case where tree structure would still be a problem?

Re-ordering in general, and sorting in particular (but also randomizing) is 
not well defined in the tree. This is really a fundamental problem of a tree 
structure. We *could* define sorting and randomizing a tree (and I guess we 
did somehow). But it is not something natural, which means the user won't 
understand it.

As was noted several times in the past, a playlist is a play list is not a 
play tree. I would argue that the "main" playlist should actually always be 
flat (as it was way way back).

However, we obviously need a hierarchy for the media library. Directories are 
one obvious use case, but also most service discoveries have some form of 
hierarchy. At least SAP, UPnP, MTP and Shoutcast have some form of hierarchy.

In the end, I would argue that the media library tree should be completely 
separate from the actual playback items list. You could just "copy" items 
either way. VLC always plays from the playlist, which can be reordered. To 
play a part of the media library, the relevant item(s) must be copied into the 
playlist first, then played. The UI may do both operations in a single user 
interaction if appropriate. This would probably be a huge implementation work.

-- 
Rémi Denis-Courmont
http://www.remlab.net/



More information about the vlc-devel mailing list