<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.13.2">
</HEAD>
<BODY>
For running multiple media players, wouldn't it be easiest to have each player have its own DBus object that implements the common library (with their own player specific features on top) and in addition have a second common DBus object "org.freedesktop.MediaPlayer" which points to the object or contains the object (I have little knowledge of how DBus works), so that when a player starts up it can launch its own DBus object and then attempt to take control of the universal name. If it fails to get the universal name, it will still work, but no calls to the universal name will get to it, just direct calls to its own object.<BR>
<BR>
I hope that made sense.<BR>
<BR>
- Brian<BR>
<BR>
On Wed, 2006-12-06 at 06:04 +0100, Milosz Derezynski wrote:<BR>
<BLOCKQUOTE TYPE=CITE>
<FONT COLOR="#000000">Allright as i've read on the transcript, you're going to implement the DBus interace as a "client" anyway.</FONT><BR>
<BR>
<BR>
<FONT COLOR="#000000">So for one: nevermind the part about "DBus or nothing", but then again what is your concern with running one player, and debugging XMMS2 the same time? </FONT><BR>
<FONT COLOR="#000000">Milosz</FONT><BR>
<BR>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<FONT COLOR="#000000">On 12/6/06, </FONT><FONT COLOR="#000000"><B>Milosz Derezynski</B></FONT><FONT COLOR="#000000"> <<A HREF="mailto:internalerror@gmail.com">internalerror@gmail.com</A>> wrote:</FONT><BR>
<BLOCKQUOTE>
<FONT COLOR="#000000">Sham:</FONT><BR>
<FONT COLOR="#000000">Yeah it would basically mean that one player can run at a time, but going with what Diego said earlier, i'd concur that it could be very well something that is not directly at the core of the application, and it can be started without exposing itself through DBus. BMPx can do this in fact if you start it with the -bin binary and pass --no-remote to it. </FONT><BR>
<BR>
<FONT COLOR="#000000">(For those unfamiliar with what i mean with -bin binary: BMPx implements a single-application-instance/application-as-service [1] mechanism using DBus activation. There is a 'remote' binary which is for all intents and purposes for the user just like the main application binary, and a "-bin" binary (similar to firefox-bin for firefox/comparable) in libexec) </FONT><BR>
<BR>
<FONT COLOR="#000000">Furthermore, and i'm aware i might be digging up probably unpleasant stuff i see the problem with XMMS2+DBus the one that there is no "real" reason for XMMS2 to not switch to DBus (yeah i know about tru's technical explanations and the don't-broadcast and no TCP/IP transport stuff but that will appear, well anyway back to the main sentence), so, basically, once XMMS2 implements a DBus interface using this common spec, there would be no _real_ reason to not to switch to DBus entirely for server<->client messaging (XMMS2 to clients for those not in the know). </FONT><BR>
<BR>
<FONT COLOR="#000000">So either this will happen (you switch entirely), or you guys will just not switch to DBus at all; everything else is just unfeasible if not at the very least from a maintenance point of view, and it would be obviously also hilarious because of other reasons to implement 2 very similar systems of which either could replace the other (except that without DBus, there will be hardly a common interface implemented.) </FONT><BR>
<BR>
<FONT COLOR="#000000">I just want to point this out right now and bring it to the surface, before we all start a chanty dance around an empty pot.</FONT><BR>
<BR>
<FONT COLOR="#000000">Everyone:</FONT><BR>
<BR>
<FONT COLOR="#000000">As for the table, it's something Sham has done some good while ago and it's a good starting point to see how common the current interfaces are. </FONT><BR>
<BR>
<FONT COLOR="#000000">Sham (again):</FONT><BR>
<BR>
<FONT COLOR="#000000">Can you wiki-fy the table and make it editable (perhaps only on request and only for people you approve for, well, namely the media player developers or the players listed there at the least, so we can quickly amend it, etc.. ? </FONT><BR>
<BR>
<FONT COLOR="#000000">Regards,</FONT><BR>
<FONT COLOR="#000000">Milosz</FONT><BR>
<BR>
<FONT COLOR="#000000">[1] <A HREF="http://live.gnome.org/DesktopAppsAsDBusServices">http://live.gnome.org/DesktopAppsAsDBusServices</A> (NOTE: We actually deployed this mechanism 1 year before Alex proposed it in his form, so our implementation differs in details, but is essentially the same; it doesn't go -as- far as putting stuff into .desktop files that could be regarded as bogus until really accepted as a spec/way to do things) </FONT>
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<BLOCKQUOTE>
<BR>
<BR>
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<BLOCKQUOTE>
<FONT COLOR="#000000">On 12/6/06, </FONT><FONT COLOR="#000000"><B>Sham Chukoury</B></FONT><FONT COLOR="#000000"> <<A HREF="mailto:eleusis@xmms.org">eleusis@xmms.org</A>> wrote:</FONT><BR>
<BLOCKQUOTE>
<FONT COLOR="#000000">Hello world.</FONT><BR>
<BR>
<FONT COLOR="#000000">Seb Ruiz wrote:</FONT><BR>
<FONT COLOR="#000000">> Actually, whilst I was in san francisco, I spoke with the xmms2 folks</FONT><BR>
<FONT COLOR="#000000">> about the same thing. we totally agreed on the necessity for it.</FONT><BR>
<BR>
<FONT COLOR="#000000">Indeed, this was discussed a bit during a meeting: [1] </FONT><BR>
<FONT COLOR="#000000">(full transcript at [2])</FONT><BR>
<BR>
<FONT COLOR="#000000">>> I've been working recently of a D-Bus [2] control interface for VLC,</FONT><BR>
<FONT COLOR="#000000">>> to permit other applications to interact with VLC.</FONT><BR>
<FONT COLOR="#000000">>> This implements basic functions such as: </FONT><BR>
<FONT COLOR="#000000">>> - playback control (Play/Pause/Next..)</FONT><BR>
<FONT COLOR="#000000">>> - information on medias (Meta-data/Length)</FONT><BR>
<FONT COLOR="#000000">>> - playlist editing (Add new elements to play)</FONT><BR>
<FONT COLOR="#000000">>></FONT><BR>
<FONT COLOR="#000000">>> I've been looking at how other media players already implemented that, </FONT><BR>
<FONT COLOR="#000000">>> and I thought all their interfaces were highly redundant, and could</FONT><BR>
<FONT COLOR="#000000">>> benefit of implementing a single, common, shared interface.</FONT><BR>
<FONT COLOR="#000000">>></FONT><BR>
<FONT COLOR="#000000">>> That would let developers use this interface in their programs, and </FONT><BR>
<FONT COLOR="#000000">>> let their users decide of which media player they wanna use. All about</FONT><BR>
<FONT COLOR="#000000">>> FREEDOM.</FONT><BR>
<BR>
<FONT COLOR="#000000">I've done a bit of work on this, though in the form of a Python library (Chalyx</FONT><BR>
<FONT COLOR="#000000">- for XMMS2 [3] and MPD [4] clients), not an open spec or interface of any kind. </FONT><BR>
<FONT COLOR="#000000">You can see the class defining the methods to be used at [5]</FONT><BR>
<FONT COLOR="#000000">It's a bit of a compromise between the interfaces provided by XMMS2 [6] and MPD</FONT><BR>
<FONT COLOR="#000000">[7] (though biased a bit towards XMMS2). You can see a table comparing the </FONT><BR>
<FONT COLOR="#000000">interfaces at [8] (Some MPRIS/BMP/BMPx calls are included, but they've never</FONT><BR>
<FONT COLOR="#000000">been implemented in Chalyx)</FONT><BR>
<BR>
<FONT COLOR="#000000">>> I've copied this specification on the videolan wiki [6], and modified</FONT><BR>
<FONT COLOR="#000000">>> it to my needs. I tried to keep it as general as possible. However </FONT><BR>
<FONT COLOR="#000000">>> this still needs more work, and comments.</FONT><BR>
<FONT COLOR="#000000">>></FONT><BR>
<FONT COLOR="#000000">>> This is why i'm reaching you, developers of some media players, to</FONT><BR>
<FONT COLOR="#000000">>> comment what i've done or work with me, until that specification </FONT><BR>
<FONT COLOR="#000000">>> fulfills your needs, and can be used in a real world.</FONT><BR>
<FONT COLOR="#000000">>></FONT><BR>
<FONT COLOR="#000000">>> This specification should stay as generic as possible, because media</FONT><BR>
<FONT COLOR="#000000">>> players that want to make specific methods available with D-Bus can do </FONT><BR>
<FONT COLOR="#000000">>> it through their specific interface.</FONT><BR>
<FONT COLOR="#000000">>></FONT><BR>
<FONT COLOR="#000000">>> For example, basic methods would be available on the service</FONT><BR>
<FONT COLOR="#000000">>> org.freedesktop.MediaPlayer and VLC would make streaming methods</FONT><BR>
<FONT COLOR="#000000">>> available on the service org.videolan.vlc. So, a basic control applet</FONT><BR>
<FONT COLOR="#000000">>> for the KDE panel originally written for amarok would be able to</FONT><BR>
<FONT COLOR="#000000">>> control VLC, and a complex pygtk script would control streaming</FONT><BR>
<FONT COLOR="#000000">>> features of VLC. </FONT><BR>
<BR>
<FONT COLOR="#000000">Re: 'The Service' on the DBus-spec page, am I to understand that only one player</FONT><BR>
<FONT COLOR="#000000">supporting the spec may be running at any one time? That makes sense from the</FONT><BR>
<FONT COLOR="#000000">point of view that the user might want a single 'default' player to control, but </FONT><BR>
<FONT COLOR="#000000">what if the user wants 2 such players running at a time? For example, listening</FONT><BR>
<FONT COLOR="#000000">to music using VLC while debugging XMMS2? ;)</FONT><BR>
<BR>
<FONT COLOR="#000000">Re: generic interface, does that mean there could be standard interface</FONT><BR>
<FONT COLOR="#000000">extensions? For example, players with access to a media library could have an </FONT><BR>
<FONT COLOR="#000000">extended interface 'org.freedesktop.MediaPlayer.Library'.</FONT><BR>
<BR>
<FONT COLOR="#000000">Cheers.</FONT><BR>
<FONT COLOR="#000000">-S</FONT><BR>
<BR>
<FONT COLOR="#000000">[1]</FONT><BR>
<FONT COLOR="#000000"><A HREF="http://wiki.xmms2.xmms.se/index.php/IRC_Meeting/2006-11-27/Minutes#Amarok_and_XMMS2_Collaboration">http://wiki.xmms2.xmms.se/index.php/IRC_Meeting/2006-11-27/Minutes#Amarok_and_XMMS2_Collaboration</A></FONT><BR>
<FONT COLOR="#000000">[2] <A HREF="http://dan.chokola.com/files/xmms2-meeting/2006-11-27/transcript.txt">http://dan.chokola.com/files/xmms2-meeting/2006-11-27/transcript.txt</A></FONT><BR>
<FONT COLOR="#000000">[3] <A HREF="http://xmms2.xmms.se/epydoc/public/xmmsclient.XMMS-class.html">http://xmms2.xmms.se/epydoc/public/xmmsclient.XMMS-class.html</A></FONT><BR>
<FONT COLOR="#000000">[4] <A HREF="http://mpd.wikia.com/wiki/MusicPlayerDaemonCommands">http://mpd.wikia.com/wiki/MusicPlayerDaemonCommands</A></FONT><BR>
<FONT COLOR="#000000">[5] <A HREF="http://git.xmms.se/?p=chalyx-eleusis.git;a=blob;f=src/Chalyx/services/service.py">http://git.xmms.se/?p=chalyx-eleusis.git;a=blob;f=src/Chalyx/services/service.py</A></FONT><BR>
<FONT COLOR="#000000">[6] <A HREF="http://git.xmms.se/?p=chalyx-eleusis.git;a=blob;f=src/Chalyx/services/xmms2.py">http://git.xmms.se/?p=chalyx-eleusis.git;a=blob;f=src/Chalyx/services/xmms2.py</A></FONT><BR>
<FONT COLOR="#000000">[7] <A HREF="http://git.xmms.se/?p=chalyx-eleusis.git;a=blob;f=src/Chalyx/services/mpd.py">http://git.xmms.se/?p=chalyx-eleusis.git;a=blob;f=src/Chalyx/services/mpd.py</A></FONT><BR>
<FONT COLOR="#000000">[8] <A HREF="http://xmms2.xmms.se/%7Eeleusis/misc/client-api-table.html">http://xmms2.xmms.se/~eleusis/misc/client-api-table.html</A></FONT>
</BLOCKQUOTE>
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<BLOCKQUOTE>
<BR>
<BR>
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE TYPE=CITE>
<BR>
<PRE>
<FONT COLOR="#000000">_______________________________________________</FONT>
<FONT COLOR="#000000">Banshee-list mailing list</FONT>
<FONT COLOR="#000000"><A HREF="mailto:Banshee-list@gnome.org">Banshee-list@gnome.org</A></FONT>
<FONT COLOR="#000000"><A HREF="http://mail.gnome.org/mailman/listinfo/banshee-list">http://mail.gnome.org/mailman/listinfo/banshee-list</A></FONT>
</PRE>
</BLOCKQUOTE>
</BODY>
</HTML>