What player can I use to repeat a specific part of an audio file? e.g. I need an audio file to repeat from second 10 to 22, in a loop. This can be done via mplayer
, but mplayer
is not visual and is hard to work with from command line:
mplayer audio.mp3 -ss 10 -endpos 12 -loop 100
VLC Media player also has a looping functionality that is available in the GUI.
Found a question on SuperUser (answered by John T and tbenz9, see Sources below), which highlights the option.
To summarise the links (in case they go dead), by activating the 'Advanced controls' from the View menu, a A-B loop button will appear in the controls. Press this once at the start of where you want the loop and press again where you want the loop to finish. VLC will then repeat that section continuously.
Alternatively, if you want to initiate it from the command line (if you already have the times), you can do the following:
Sources:
AB Loop Player on GitLab runs in the web browser. AB loops can be bookmarked and annotated for later sessions. The A and B marks can be fine-tuned using slider handles, arrow keys or time-input fields. It supports a number of video and audio file formats as well as YouTube videos. Slow and fast motion is available.
You can use Audacity. First install
Audacity
by:Open your file in
Audacity
and create a loop by selecting start and end of the loop, then copy/paste it wherever you want.A complete tutorial is available in the official documentation or if you like videos, in YouTube.