[vlc-devel] MPRIS on VLAN

Mirsal Ennaime mirsal at videolan.org
Tue Feb 7 07:00:38 CET 2012


Hi Kevin,

I cc'd the list as this might be of interest to other people.

On Sun, 2012-02-05 at 20:34 -0500, Kevin Anthony wrote:
> On Fri, Feb 3, 2012 at 5:32 AM, Mirsal <mirsal at videolan.org> wrote:
> > On Thu, 2012-02-02 at 16:34 -0500, Kevin Anthony wrote:
> > > I've been working on this, but i cannot get VLC's dbus to
> > > work on my machine, i keep getting a '.service file not found'
> > > in python.
> >
> > .service files are only useful for dbus activation,
> > you are getting this error because VLC has not registered the bus
> > name you are trying to reach.
> >
> > Please check that all of the following are true:
> >
> > - Your VLC was built with mpris2 support
> >
> > - The dbus module is loaded in VLC 
> >   (use vlc --control dbus in order to force it to start
> >   if it is not enabled by default)
> >
> > - You are trying to reach the correct object path
> >   (which is /org/mpris/MediaPlayer2) on the correct
> >   bus name (which is org.mpris.MediaPlayer2.vlc)
> >
> > If something goes wrong then, try with vlc 2.0-rc1.
> >
> > > i created the file
> > > in /usr/share/dbus-1/org.freedesktop.MediaPlayer.service
> >
> > Remove it, it is useless unless you need dbus-activation, plus the
> > bus name is not correct. Please check the current mpris spec at
> > http://mpris.org 
>
> I got it working this morning,

Great :)

> however it segfaults when a user asked for the property Fullscreen or
> set Fullscreen.

'time to use your gdb-fu or send us a patch so we can help you debug.

>   I've been searching for a way of checking to see if the player is
> playing, but i have not found a reliable one.

You can find one in modules/control/dbus/dbus_player.c circa line 470,
but be very careful with memory and concurrency / locking issues as this
is data which is accessed by concurrent threads.

> Do we leave it up to the user to check playing state before calling
> this property?

no, because the check would be racy. There is no way to read then write
atomically to a d-bus property so VLC has to do it.
> 
All the best,

-- 
mirsal
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: This is a digitally signed message part
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20120207/2a7b9a00/attachment.sig>


More information about the vlc-devel mailing list