summaryrefslogtreecommitdiff
path: root/spec/all.xml
blob: 8549de4fceadbb32a28eca2b9c716fb0c3c46444 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
<tp:spec
  xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"
  xmlns:xi="http://www.w3.org/2001/XInclude">

  <tp:title>MPRIS D-Bus Interface Specification</tp:title>
  <tp:version>2.2</tp:version>

  <tp:copyright>
    Copyright © 2006-2012 the VideoLAN team
    (Mirsal Ennaime, Rafaël Carré, Jean-Paul Saman)
  </tp:copyright>
  <tp:copyright>Copyright © 2005-2008 Milosz Derezynski</tp:copyright>
  <tp:copyright>Copyright © 2008 Nick Welch</tp:copyright>
  <tp:copyright>Copyright © 2010-2012 Alex Merry</tp:copyright>

  <tp:license xmlns="http://www.w3.org/1999/xhtml">
    <p>
      This library is free software; you can redistribute it and/or
      modify it under the terms of the GNU Lesser General Public
      License as published by the Free Software Foundation; either
      version 2.1 of the License, or (at your option) any later
      version.
    </p>

    <p>
      This library is distributed in the hope that it will be useful,
      but WITHOUT ANY WARRANTY; without even the implied warranty of
      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      GNU Lesser General Public License for more details.
    </p>

    <p>
      You should have received a copy of the GNU Lesser General
      Public License along with this library; if not, write to the
      Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
      Boston, MA 02110-1301, USA.
    </p>
  </tp:license>

  <tp:section name="About">
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <p>
        The Media Player Remote Interfacing Specification is a standard
        <a href="http://www.freedesktop.org/wiki/Software/dbus">D-Bus</a>
        interface which aims to provide a common programmatic API
        for controlling media players.
      </p>
      <p>
        It provides a mechanism for discovery, querying and basic playback
        control of compliant media players, as well as a tracklist
        interface which is used to add context to the active media item.
      </p>
    </tp:docstring>
  </tp:section>

  <tp:section name="Changes">
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <dl>
        <dt>From 2.1 to 2.2:</dt>
        <dd>
          <ul>
            <li>
              Added the optional <b>Fullscreen</b> and <b>CanSetFullscreen</b> properties
              to the <b>org.mpris.MediaPlayer2</b> interface.
            </li>
            <li>
              The path <b>/org/mpris/MediaPlayer2/TrackList/NoTrack</b> now represents
              "no track" where required in the <b>org.mpris.MediaPlayer2.TrackList</b>
              interface (since empty paths are not allowed by D-Bus).
            </li>
            <li>
              The suggested unique instance identifier no longer violates the D-Bus
              specification by begining with a digit.
            </li>
          </ul>
        </dd>
        <dt>From 2.0 to 2.1:</dt>
        <dd>Added the optional <b>org.mpris.MediaPlayer2.Playlists</b> interface.</dd>
      </dl>
    </tp:docstring>
  </tp:section>

  <!-- (Only list corrections to the current version)
  <tp:section name="Corrections">
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <ul>
        <li>
          2010-09-26: Added EmitsChangedSignal annotation to Volume property
          on the Player interface.
        </li>
        <li>
          2011-01-26: Added PlaylistChanged signal to the Playlists interface.
        </li>
        <li>
          2011-11-04: Clarified the type of the mpris:trackid entry in the
          Metadata property of the Player interface.
        </li>
      </ul>
    </tp:docstring>
  </tp:section>
-->

  <tp:section name="Bus Name Policy">
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <p>
        Each media player <strong>must</strong> request a unique bus name
        which begins with <b>org.mpris.MediaPlayer2</b>. For example:
      </p>
      <ul>
        <li>org.mpris.MediaPlayer2.audacious</li>
        <li>org.mpris.MediaPlayer2.vlc</li>
        <li>org.mpris.MediaPlayer2.bmp</li>
        <li>org.mpris.MediaPlayer2.xmms2</li>
      </ul>

      <p>
        This allows clients to list available media players
        (either already running or which can be started via D-Bus activation)
      </p>

      <p>
        In the case where the media player allows multiple instances running
        simultaneously, each additional instance should request a unique bus
        name, adding a dot and a unique identifier to its usual bus name, such
        as one based on a UNIX process id.

        For example, this could be:
      </p>

      <ul>
          <li>org.mpris.MediaPlayer2.vlc.instance7389</li>
      </ul>

      <p>
        Note: According to the <a href="http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-names-bus">
        D-Bus specification</a>, the unique identifier "must only contain the
        ASCII characters '[A-Z][a-z][0-9]_-'" and "must not begin with a digit".
      </p>

    </tp:docstring>
  </tp:section>

  <tp:section name="Entry point">
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">

      <p>
        The media player <strong>must</strong> expose the
        <strong>/org/mpris/MediaPlayer2</strong> object path, which
        <strong>must</strong> implement the following interfaces:
      </p>

      <ul>
        <li>org.mpris.MediaPlayer2</li>
        <li>org.mpris.MediaPlayer2.Player</li>
      </ul>

      <p>
        The <strong>/org/mpris/MediaPlayer2</strong> object may implement
        the <strong>org.mpris.MediaPlayer2.TrackList</strong> interface.
      </p>

      <p>
        The <strong>/org/mpris/MediaPlayer2</strong> object may implement
        the <strong>org.mpris.MediaPlayer2.Playlists</strong> interface.
      </p>

    </tp:docstring>
  </tp:section>

  <tp:section name="The PropertiesChanged signal">
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <p>
        The <abbr title="Media Player Remote Interfacing Specification">MPRIS</abbr>
        uses the <literal>org.freedesktop.DBus.Properties.PropertiesChanged</literal>
        signal to notify clients of changes in the media player state.
        If a client implementation uses D-Bus bindings which do not support this
        signal, then it should connect to it manually.
        If a media player implementation uses D-Bus bindings which do not support
        this signal, then it should send it manually
      </p>
    </tp:docstring>
  </tp:section>

  <tp:section name="Interfaces">
    <xi:include href="Root_Node.xml" />
    <xi:include href="TrackList_Node.xml" />
    <xi:include href="Player_Node.xml" />
    <xi:include href="Playlists.xml" />
  </tp:section>

</tp:spec>
<!-- vim:set sw=2 sts=2 et ft=xml: -->