Lowrent;143942 Wrote: 
> 
> Would it be easy to program a plugin that would allow me to browse by
> label or source.
> I would also like to add that information in the file information in
> Now Playing.With the Custom Browse plugin you can create browse menus based 
> on any
information thats stored in the slimserver database. The problem with
LABEL and SOURCE is that these tags will not be stored in the
slimserver database. As I see it you have a number of solutions:

1. Store the information in one of the tags that slimserver is able to
handle and use the Custom Browse plugin. You could for example use the
COMMENT tag which is imported to the slimserver database.

2. Make a plugin that implements a custom scanning process. I'm not
completely sure, but I think there is no way to hook in your code so
its called for every scanned track. But I know you can make a custom
scanner that scans all files by it self. To make it as simple as
possible its probably best to make the scanner with an algoritm like:
- Read all tracks from the slimserver database
- For each file read the LABEL and SOURCE tags
- Store the information in the LABEL and SOURCE tag in a new separate
table and use the track identifier (or url) as the key
When you have the information in the slimserver database you can use
the Custom Browse plugin to make the browse menu.

3. You can make a plugin that reads the information from the tags in
runtime, the problem here is performance. If you have a browse menu
that lists all tracks with source=vinyl you would have to read all
tracks in slimserver database and detect which one is vinyl or not.
Doing this at the time the user right click will probably not work
since it will take to much time. So some sort of caching has to be
done, which also brings us back to solution 2.

Of course you don't have to use the Custom Browse plugin at all, you
can also implement the browse mechanism in your own plugin. But
indepdendent if you use the Custom Browse plugin or not I think you
will have to start with getting the information into the slimserver
database.

I don't think its possible for a plugin to add information to the Now
Playing sub menus, but it might have changed since I looked at it last
time.


-- 
erland

Erland Isaksson
'My homepage' (http://erland.homeip.net) 'My download page'
(http://erland.homeip.net/download)
(Developer of 'TrackStat'
(http://erland.homeip.net/download/do/viewapplication?name=slimserver-trackstat)
, 'SQLPlayList'
(http://erland.homeip.net/download/do/viewapplication?name=slimserver-sqlplaylist)
, 'DynamicPlayList'
(http://erland.homeip.net/download/do/viewapplication?name=slimserver-dynamicplaylist),
'Custom Browse'
(http://erland.homeip.net/download/do/viewapplication?name=slimserver-custombrowse)
and 'RandomPlayList'
(http://erland.homeip.net/download/do/viewapplication?name=slimserver-randomplaylist)
plugins)
------------------------------------------------------------------------
erland's Profile: http://forums.slimdevices.com/member.php?userid=3124
View this thread: http://forums.slimdevices.com/showthread.php?t=28399

_______________________________________________
discuss mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/discuss

Reply via email to