pub struct MediaCapabilities {
pub seeking: bool,
pub speed: bool,
pub looping: bool,
pub analysis: bool,
pub session: bool,
pub equalizer: bool,
pub probing: bool,
}Expand description
What a platform media stack can actually do.
Reported rather than assumed: a screen greys out a speed control the device will not honour instead of offering one that silently does nothing.
Fields§
§seeking: boolWhether seek_media moves the position.
speed: boolWhether set_media_speed changes the rate.
looping: boolWhether set_media_looping repeats the item when it ends.
analysis: boolWhether the backend can publish MediaSamples while it plays.
session: boolWhether metadata reaches a platform media session — the lock screen, the notification, the headset buttons.
equalizer: boolWhether the backend has an equalizer. The bands it has are reported by
media_equalizer_bands, because a platform effect has the bands its
implementation has rather than the ones a screen would like.
probing: boolWhether probe_media_duration can read an item’s length without
playing it. A playlist that shows durations for entries nobody has
opened needs this; one that does not, does not.
Implementations§
Source§impl MediaCapabilities
impl MediaCapabilities
Sourcepub const TRANSPORT: MediaCapabilities
pub const TRANSPORT: MediaCapabilities
A backend that plays, pauses and seeks and does nothing else, which is the floor for anything worth calling a media player.