Playback

This page explains what Nastro plays and exactly what the transport does in each situation: when a track ends, when you press Next, when a file cannot be read.

Supported formats

Nastro decodes these file extensions, in upper or lower case. Some of them are containers that can hold more than one codec, so the table also says which codecs inside them play:

FormatExtensionsCodecs
FLACflacFLAC
MP3 and MPEG audiomp3, mp2, mp1MP3, MP2, MP1
Oggogg, oga, opusVorbis, Opus, FLAC
WAVwav, wavePCM, ADPCM
AIFFaif, aiff, aifcPCM
MPEG-4 audiom4a, mp4, m4b, aacAAC, ALAC
Core AudiocafPCM, ALAC, AAC
Matroska and WebMmka, mkv, webmOpus, Vorbis, FLAC, MP3, AAC, ALAC, PCM

Files with any other extension are ignored when you add them. Nastro decides by the extension, so a supported extension on a file whose contents it cannot decode is added to the playlist and then skipped when its turn comes, see Errors and skipped tracks.

WavPack (.wv) and Monkey's Audio (.ape) are not supported yet.

Opus always plays at 48 kHz, whatever the rate of the original recording, so the display shows 48 kHz for every Opus file. Matroska and WebM files do not show the title that ffmpeg and most tools store in them, so they show their file name instead.

Nastro reads the title, artist, album and genre tags, and the length, of every file you add. A track without a title tag shows its file name without the extension. While a track plays, the display shows the codec, the bitrate when known, the sample rate and the channels, see The display.

If the sample rate of a file differs from the one of your audio output, Nastro resamples it. More than two channels are mixed down to stereo, and a mono file plays on both speakers.

The transport

The buttons of the player, the Play menu and the keyboard shortcuts run the same commands.

CommandWhat it does
Play Paused: resumes. Playing: restarts the track from the beginning. Stopped with a track loaded: plays it from the beginning. Nothing loaded: plays the track that was loaded when you last quit, otherwise the first selected track of the playlist shown, otherwise its first track.
PausePlaying: pauses. Paused: resumes. Stopped: does nothing.
Play or pause (Space)Pauses when playing, otherwise does what Play does.
StopStops and puts the position back at the start. The track stays loaded, so Play starts it again.
NextPlays the next track in the play order. After the last track it wraps to the first, even with repeat off.
PreviousPlays the previous track in the play order. Before the first track it wraps to the last. It always changes track, it does not restart the current one.

With nothing loaded, Next and Previous both play the first track of the play order of the playlist shown. Next and Previous act on the playlist of the track that is loaded, which can be a different tab from the one you are looking at. A double click on a track in the playlist, or Enter on the selected one, plays it right away.

Gapless playback

While a track plays, Nastro hands the audio engine the track that comes next, so it starts the moment the previous one ends, with no silence in between. The queued track follows the play order, so it respects shuffle and repeat, and it is replaced whenever you change the playlist, shuffle or repeat. Albums recorded to flow from one song into the next play as intended.

Shuffle and repeat

Turn them on and off with the SHUFFLE and REPEAT buttons of the player, the Play menu or S and R. Both are remembered between sessions.

  • Neither: tracks play in playlist order and playback stops after the last one.
  • Repeat: after the last track, the first one plays again. Repeat repeats the whole playlist, not a single track.
  • Shuffle: Nastro plays a random order of the playlist in which every track plays once before any repeats. The track already playing goes first, so turning shuffle on does not interrupt it. Previous walks back along the shuffled order. Changing the playlist (adding, removing, sorting) makes a new shuffled order.
  • Shuffle and repeat together: when the shuffled order runs out, a new shuffled order starts, and it never begins with the track that just played.

The filter of the playlist only changes which tracks are shown. It does not change the play order.

At the end of the playlist

With repeat off, when the last track ends (in shuffle: when the last track of the shuffled order ends) playback stops. The state glyph of the display changes to stop and the last track stays loaded. With repeat on, playback continues from the beginning.

Seeking

Click or drag the seek bar under the display. While you drag, only the thumb and the clock move, and Nastro jumps to that point when you release the button. The seek bar does nothing while no track is loaded or when the length of the file is not known.

← and → (and Back 5 seconds and Forward 5 seconds in the Play menu) jump 5 seconds. Forward never goes past the end of the track.

Volume and balance

The volume slider moves in steps of 1 %, and the volume keys ↑ and ↓ change it by 5 %. The default is 80 %. The slider does not control the volume linearly: the sound level follows the cube of the slider position, so equal movements of the slider sound like equal changes in loudness. At the middle of the slider the sound is 18 dB quieter than at the top, a tenth of the way up it is 60 dB quieter, and at the far left there is silence.

The BAL slider moves the sound between the left and the right speaker by turning the other side down, never by turning the near side up. Near the middle it snaps to the exact centre, where both sides are at full level, so you can find it without looking. Changes of volume and balance are smoothed over a few milliseconds, so they never click.

Volume and balance are remembered between sessions. See also The equalizer, which is applied before the volume.

Errors and skipped tracks

When a track cannot be played, for example because the file was moved, is damaged or is in a format Nastro does not decode, or when there is no audio output, the display shows the error in place of the track line until the next track starts. If the failure belongs to a file, Nastro skips to the next track in the play order. If every track of the playlist fails one after another, Nastro stops trying instead of looping forever. The reason is written to the log.

Files given on the command line

Files, folders and playlists passed as arguments are added to the playlist shown and the first one added starts playing:

$ nastro ~/Music/album/*.flac
$ nastro ~/Music/Jazz

Only one Nastro runs at a time on Linux and macOS. When it is already running, opening files with Nastro (from the file manager, or nastro with files in a terminal) adds them to the running player, to the playlist shown, and plays the first one; starting it again without files just brings its window to the front. On Windows each start is a separate player for now. On macOS, files you open with Nastro from Finder, or drop on its Dock icon, are handled the same way while it is running. Folders and playlists are read as described in Adding tracks. Without arguments, Nastro starts with the playlists of your last session and does not play anything until you press Play.

Found a mistake? Edit this page on GitHub or open an issue.

↑↓to move ↵to open /or Ctrl Kto search from any page