Documentation
¶
Overview ¶
Media Player Metadata
REFERENCE: https://www.freedesktop.org/wiki/Specifications/mpris-spec/metadata/
NOTE: This is currently linux-only.
TODO: Add Windows/macOS Implementations also.
Copyright (C) 2023 Goutham Krishna K V
Index ¶
Constants ¶
View Source
const ( LoopStatusNone = "None" LoopStatusTrack = "Track" LoopStatusPlaylist = "Playlist" LoopStatusError = "LoopStatusError" )
View Source
const ( // MPRIS specific TRACKID = "mpris:trackid" LENGTH = "mpris:length" ART_URL = "mpris:artUrl" // Xesam specific TITLE = "xesam:title" ARTIST = "xesam:artist" ALBUM = "xesam:album" ALBUM_ARTIST = "xesam:albumArtist" URL = `xesam:url` )
View Source
const ( // -- PLAYBACK STATUS -- // Support // - Windows // - Linux // - macOS (* needs to be built as proxy using AVPlayer.rate == 0) PlaybackStatusPlaying = "Playing" PlaybackStatusPaused = "Paused" // Support // - Windows // - Linux PlaybackStatusStopped = "Stopped" // Support // - Windows PlaybackStatusChanging = "Changing" PlaybackStatusClosed = "Closed" PlaybackStatusError = "PlaybackStatusError" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FullMetadata ¶
type FullMetadata struct {
PlaybackStatus string `msgpack:"playbackStatus"` // RO
LoopStatus *string `msgpack:"loopStatus"` // RW (Optional)
Rate float64 `msgpack:"rate"` // RW
Shuffle *bool `msgpack:"shuffleEnabled"` // RW (Optional)
Metadata *Metadata `msgpack:"metadata"` // RO
Volume float64 `msgpack:"volume"` // RW
Position int64 `msgpack:"position"` // RO
MinimumRate float64 `msgpack:"minimumRate"` // RO
MaximumRate float64 `msgpack:"maximumRate"` // RO
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack)
type LoopStatus ¶
type LoopStatus string
type MPlayerList ¶
type MPlayerList struct {
Players []string
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack)
type Metadata ¶
type Metadata struct {
TrackId string `msgpack:"trackid"`
Length uint64 `msgpack:"length"`
Title string `msgpack:"title"`
Artist []string `msgpack:"artist"`
Album string `msgpack:"album"`
AlbumArtist []string `msgpack:"albumArtist"`
Url string `msgpack:"url"`
ArtUrl string `msgpack:"artUrl"`
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack)
type PlaybackStatus ¶
type PlaybackStatus string
type PlayerData ¶
type PlayerData struct {
PlayerName string
PlaybackStatus string
Metadata Metadata
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack)
type PlayerIndex ¶
type PlayerIndex struct {
PlayerIndex int
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack)
type PropertiesChangedSignal ¶
type PropertiesChangedSignal struct {
PlayerName string `msgpack:"playerName"`
PlayerIdx int `msgpack:"playerIdx"`
PlayerDataVal *FullMetadata `msgpack:"playerData"`
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack)
type SetupStatus ¶
type SetupStatus struct {
Statuses []Status `msgpack:"statuses"`
// contains filtered or unexported fields
}
TODO: Remove field names (we use array-style msgpack) TODO: Rename it to better reflect it's purpose.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.