|
Rockbox mail archiveSubject: Re: new rockbox playlist formatRe: new rockbox playlist format
From: Ray Lambert <listlizard_at_interthingy.net>
Date: Sat, 10 Dec 2005 14:26:09 -0500 Martin Borus wrote: >if Rockbox got more playlist commands, these are some I'd use: > >- pick random song from directory (incl/excl subdirectory) >- pick next song from directory (needs to keep track of last track played in >directory) >- pick random song from playlist >- pick next song from playlist (needs to keep track of last track played in >list) >- pick random song from database query > >These three are needed for this: >- loop structure (Example: Loop 20 {pick one random from current hits >directory; pick one random from alltimefavorites-playlist } ) > > It looks like all you want is to make random mix playlists from selected directories/playlists. I don't see a need to introduce looping or any other logical construct to achieve this. I satisfied your need by adding "shuffle" and "count=n" keywords to the 'match' and 'select' directives and by allowing the 'match' directive to match against playlist contents (in addition to directory contents). Your example might be implemented as such: ! config shuffle: on ! match recursive shuffle count=20 /current-hits ! match shuffle count=20 /playlists/alltimefavorites.m3u Remember that I'm approaching this currently as a means to generate static M3U files that can be played by both the existing rockbox playlist support mechanism and other applications on your PC. This prevents the inclusion of any commands that must be executed dynamically, while the playlist is playing (i.e. looping; although static looping -- at read time -- would be possible). This approach is intended to provide some level of compatibility with other SW and reduce the upfront development effort. If someone demonstrates a compelling reason to abandon this approach then I will consider doing so. So, here's the updated proposed spec. Please post your comments... ---------------------------------------------- Proposed Rockbox Playlist Format (version 2): - filename extension: .BOX - # comment - ! config config-statement[; config-statement] - ! config load <any config file> - ! include /path/playlist<.BOX|.M3U> - [/][path/][filename.ext] - ! match [recursive] [shuffle] [count=n] /path/dirname[/<regexp>|<playlist<.box|.m3u>>] - ! select [shuffle] [count=n] <database query TBD> - ! playlist-file <playlist[.m3u]> - ! generate-only - ! auto-cleanup - ! windows-drive-letter <A-Z> Notes: - 'playlist-file' is used to override the default output (M3U) file name, which is derived from the .BOX file name - 'generate-only' tells the .BOX player to only generate an M3U and not to play it. - 'auto-cleanup' tells the .BOX player to automatically delete the generated M3U file when it finishes playing. (This may prove difficult or impossible to implement.) - 'windows-drive-letter' indicates which drive letter to write to the M3U file. Default is none. - The 'shuffle' option on the 'match' and 'select' directives causes the resulting list of songs to be randomized. This affects only the results of the single directive. To randomize the entire playlist the shuffle config option (! config shuffle: on) must be specified. - The 'count=n' option on the 'match' and 'select' directives causes the resulting list of songs to be truncated to 'n' number of songs. This is probably most useful in conjunction with the 'shuffle' option. ---------------------------------------------- Received on 2005-12-10 Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy |