On Sun, 2006-10-22 at 13:04 +0100, Jamie McCracken wrote: > James "Doc" Livingston wrote: > > Second, what would be the best way of asking Tracker for all the music > > files? Calling tracker_search_text() with the search string being NULL > > or "" doesn't work, and complains about the lack of search terms. > > In tracker, "Music" is a first class object/service so you can get all > music files very efficiently by calling GetByServiceType in the Files > interface in Dbus or use the equivalent api call in libtrackerclient.
Thanks. I guessed there would be something, but I missed that call when reading through the API. > Hope that helps - it will be cool to get this into rhythmbox to help > dispel some of the myths/FUD being propogated on d-d-l wrt tracker's > inclusion in GNOME. I've got a trivial plugin written that asks Tracker for it's list of music files on startup and asks Rhythmbox to add them if they aren't already in the library. It doesn't get the metadata from Tracker or anything, just gets the list of URIs. > Also once I have the Music dbus interface completed and HAL/Live query > support going it would be great if Rhythmbox could auto-detect tracker Adding support for Tracker is something that I'm interested in (and I know other people are too). > and use it automatically if its installed for its main database (should > be a lot faster than an xml database when number of music files is > large) - you can use Dbus directly to manipulate tracker so there's no > need to link to or have hard dependencies on tracker. XML is only used in the on-disk representation, in memory it's a custom object-oriented hierarchical database. I'm not sure whether using tracker would be faster or not, but it doesn't really matter - whenever RB seems slow, it's almost never the database, but usually updating the UI. The question is how much of our database layer to replace. It would be easy enough to replace only the xml-loading bit, so we get the list of tracks and metadata from Tracker, but use our own in memory db for queries. Replacing the majority of RB's db layer probably means us doing the cleanup/refactor that we've been planning to do for quite a while. Cheers, James "Doc" Livingston -- "Scientia non habet inimicum nisi ignorantem" (Science has no enemies but the ignorant"). - Latin maxim _______________________________________________ tracker-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/tracker-list
