I've created a WAV file that loops perfectly, as verified by using Loop Play in the Audacity audio editor. I want to keep the file small and have my media player loop it rather than having the file repeat its content over and over. I used to use Media Player Classic for this, but I just tried with the latest version and it pauses slightly before looping (just like standard WMP, VLC, and other clients I've tried). Are there any media players that will do this properly with no intervening gap? Opening it in Audacity and manually starting a loop is more hassle than I'm interested in doing every time I want to listen.
-
Could you please list all the clients you have tried?– Franck DernoncourtJun 24, 2014 at 3:07
-
1I have never noticed a significant delay in looping with VLC so it is probably a buffering problem - have you tried putting two copies of the file into a playlist and looping the playlist?– Steve BarnesJun 24, 2014 at 5:25
-
@SteveBarnes No improvement in VLC with a playlist. WMP actually does a bit better with a playlist but there's still noticeable delay.– Matthew ReadJun 24, 2014 at 20:34
-
1@SteveBarnes I don't have that enabled and my reads for any other purpose are quite fast. Using an SSD and so on. The file is also 13 kB.– Matthew ReadJun 25, 2014 at 8:02
-
1There are plans to add gapless playback in VLC Player 4.0.– StevoisiakJun 24, 2020 at 18:41
5 Answers
Foobar2000 should support gapless playback - its supposed to work for lossless tracks, and WAV is, well not compressed, so is as lossless as they come. You'll likely need to create a playlist with a single track, and pick "Repeat(Track)" under Playback. You might also consider converting it to flac and playing around with metadata as suggested here, if that dosen't work
Mplayer is a media player for Linux and Windows that does gapless playback (no silence between tracks) including in loop mode. On the command line this is achieved with the -loop 0
option (infinite loop).
MPlayer is a movie player which runs on many systems (see the documentation). It plays most MPEG/VOB, AVI, Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, RealMedia, Matroska, NUT, NuppelVideo, FLI, YUV4MPEG, FILM, RoQ, PVA files, supported by many native, XAnim, and Win32 DLL codecs. You can watch VideoCD, SVCD, DVD, 3ivx, DivX 3/4/5, WMV and even H.264 movies.
If you want a graphical interface for Mplayer, check SMplayer
-
It's 2022 and SMPlayer under Windows does NOT work properly. Is there some setting required for it to properly invoke mplayer?– MichaelOct 14, 2022 at 22:22
-
mplayer.exe -loop 0
has a significant delay between instances of the loop.– MichaelOct 14, 2022 at 22:24 -
mplayer.exe <file> -loop 0
isn't quite seamless, there's a loud "click" or "pop" in between each loop.– MichaelOct 15, 2022 at 1:16 -
I think you may have inadvertently answered your own question. You say an older version of Media Player Classic worked the way you like. Well, Media Player Classic is a portable app, meaning you can use it without installing anything. So get the version you used to use, and use that for that file.
If that doesn't work, then the problem is either something on your system that has changed, or you've misremembered what app you previously used.
-
If I knew the version I used years ago I would be posting here. This isn't helpful. Jul 16, 2014 at 1:24
-
@MatthewRead That's too bad. I wish that information was in your Question. At least my Answer got your Question bumped and is why you now have a few other programs to try. And, if those fail, I will point out that you can at least guess the early version based on approximately how long ago it was.– trlklyJul 16, 2014 at 1:43
-
-
@modiX From what I found in a Google search, it's in the menu (as Repeat File) in newer versions, and in the settings in older versions.– trlklyJun 20, 2017 at 23:29
Assuming that you need this to loop a small file and that you are not worried about good looking GUI why not:
- Download and install Python.
- Download and install PyAudio.
- Write a simple script that:
- reads the whole file into RAM and Initialise the Audio port for output and
- in a blocking loop write the data you read above to the Audio Output
Or even - if you are on windows:
- Download and install Python
Use a script like:
import winsound as w
data = open.("YourWavFile.wav", "rb").read(-1)
while(True):
w.PlaySound(data, w.SND_MEMORY | w.SND_NOSTOP)
Stop with
control-C
You can even do this directly in the python console and if you need a GUI you could add one using a variety of libraries.
-
PlaySound() seems to expect a string for its first argument (
TypeError: must be str or None, not bytes
), so this doesn't work. Using the filename for that string does not work either. In any case, I am looking for a proper media player. Jun 26, 2014 at 0:07 -
Sounds like there may be a problem with WinSound on Python 3 - there is Issue 11620* should work with Python 2.7.x but if you need a GUI... Jun 26, 2014 at 6:29
-
Although
winsound
appears to be a standard module, it isn't found on my cygwin system.– MichaelJul 25, 2015 at 21:12
There's a software called djv view,try that out.Loops like butter. It can even show exr files and that's a super plus.