The functionality you suggest is mostly supported by the RandomPlay
plugin written by Max Spicer. I use it a lot and it's now part of the
6.5 standard (not sure about previous releases).
However this won't have all the features your system has, but I think
there is a lot of scope for reuse, and I have thought for some time
that there is a 'design solution' for this functionality.
If we had a plugin that modularised track selection then users could
develop modules for track selection with relative ease without having
to worry about the playlist management. I have in mind an object that
supports the following:
1) $obj->getNextTrackToPlay($client)
2) $obj->setupGroup()
In addition the existing SQL play / Random play plugins would be
developed into a single plugin that is initialised with a dynamic
playlist like the above.
For my purposes I considered this as I wanted to use Random Play
roughly as it is now, but with a filter to exclude certain files. My
intention was to refactor Random Play to be:
PlayerManager -> RandomPlayTrackSelector
the then write a trivial filter to have:
Player Manager -> MyFilter -> RandomPlayTrackSelector
which could be (in pseudocode) as simple as:
package My Filter;
use RandomPlayTrackSelector;
sub getNextTrackToPlay {
while ($nextTrack = RandomPlayTrackSelector->getNextTrackToPlay &&
$nextTrack->genre !~ /HateIt/) {};
return $nextTrack;
}
Malcolm
--
mwphoto
------------------------------------------------------------------------
mwphoto's Profile: http://forums.slimdevices.com/member.php?userid=652
View this thread: http://forums.slimdevices.com/showthread.php?t=20533
_______________________________________________
plugins mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/plugins