Queue-based player with native ReplayGain and Rockbox crossfade.
A player owns a live audio output device and a background engine thread, so it only works where an output device exists. The handle is a NIF resource, freed by the BEAM garbage collector (which stops playback).
ReplayGain mode here uses the player values: 0 off, 1 track,
2 album. Crossfade mode: 0 off, 1 auto-skip, 2 manual-skip,
3 shuffle, 4 shuffle-or-manual, 5 always. Mix mode: 0 crossfade,
1 mix.
Summary
Functions
Create a player on the default device with default settings.
Create a player with configuration overrides (see @default_config keys).
sample_rate: 0 means the device default.
Replace the queue with a list of file paths.
A snapshot of the player's status as an atom-keyed map.
Types
Functions
@spec new() :: t() | nil
Create a player on the default device with default settings.
Create a player with configuration overrides (see @default_config keys).
sample_rate: 0 means the device default.
@spec next(t()) :: :ok
@spec pause(t()) :: :ok
@spec play(t()) :: :ok
@spec previous(t()) :: :ok
@spec sample_rate(t()) :: non_neg_integer()
@spec seek_ms(t(), non_neg_integer()) :: :ok
Replace the queue with a list of file paths.
@spec skip_to(t(), non_neg_integer()) :: :ok
A snapshot of the player's status as an atom-keyed map.
@spec stop(t()) :: :ok
@spec toggle(t()) :: :ok