HydrogenAudio

Hydrogenaudio Forum => General Audio => Topic started by: tommedema on 2008-08-04 14:14:14

Title: Command line gapless windows audio player?
Post by: tommedema on 2008-08-04 14:14:14
Hi,

I've been looking for a commandline .exe that can queue multiple audio files and add new files to the queue while playing an audio file. It must be gapless, so when it goes from 1.mp3 to 2.mp3 there must be no sound disruption etc.

It may not have an interface. I want to use it to create a program using AutoIT.

I started my search a couple of months ago and still haven't found anything that matches what I need.. so it's not on google or anything, but maybe someone knows a program that is not very known and thus not on google?

Best regards,
Tom
Title: Command line gapless windows audio player?
Post by: M on 2008-08-04 16:01:09
Use MPlayer (http://www.mplayerhq.hu) as a back-end, perhaps? Pretty well known and gives you a heck of a lot more functionality than just MP3 (but the website documentation doesn't explicitly mention "gapless," which might explain why you missed it).

    - M.
Title: Command line gapless windows audio player?
Post by: senab on 2008-08-04 16:04:17
MPD (http://www.musicpd.org/) is the way to go.
Title: Command line gapless windows audio player?
Post by: spoon on 2008-08-04 21:01:08
As luck would have it, straight out of our R&B labs, we are releasing something tomorrow you will be interested in (no doubt), it will be billed as the most efficient (both memory and resources), gapless (and replaygian-able), multi zone audio player (designed to have as many as 10 simultaneous players running, including zones bridged together). Part 1 is done which the uPlayer which is controlled by the command line.
Title: Command line gapless windows audio player?
Post by: donnie on 2008-08-04 21:53:47
mpd or possibly xmms2. Don't know how good the windows support is on either of those though
Title: Command line gapless windows audio player?
Post by: bhoar on 2008-08-04 22:21:13
As luck would have it, straight out of our R&B labs, we are releasing something tomorrow you will be interested in (no doubt), it will be billed as the most efficient (both memory and resources), gapless (and replaygian-able), multi zone audio player (designed to have as many as 10 simultaneous players running, including zones bridged together). Part 1 is done which the uPlayer which is controlled by the command line.


Spoon -

I love that you have R&B labs.  That's cool. 

-brendan
Title: Command line gapless windows audio player?
Post by: tommedema on 2008-08-04 22:33:42
@m
thanks, however I tried it and it gives a small but noticeable gap between multiple audio files, don't you have this?

@senab
strange enough I could not find a binary file for windows for this tool, is that correct?

@spoon
thanks, I'd like to try that program out, but does it support gapless playback?

@donnie
I tried xmms2 but it does not seem to playback gapless either..

So no luck yet.. or you guys do manage to playback gapless? (without any sound disruption when it goes from file 1 to file 2)
Title: Command line gapless windows audio player?
Post by: M on 2008-08-04 22:46:00
@m
thanks, however I tried it and it gives a small but noticeable gap between multiple audio files, don't you have this?

No, I don't have that problem... but then, I am not using MPlayer! I was under the impression that it did support gapless (and I was pretty sure I remembered hearing it demonstrated at some point), but if I was mistaken I offer humble apologies for sending you on a goose-chase.

    - M.
Title: Command line gapless windows audio player?
Post by: tommedema on 2008-08-04 22:58:27

@m
thanks, however I tried it and it gives a small but noticeable gap between multiple audio files, don't you have this?

No, I don't have that problem... but then, I am not using MPlayer! I was under the impression that it did support gapless (and I was pretty sure I remembered hearing it demonstrated at some point), but if I was mistaken I offer humble apologies for sending you on a goose-chase.

    - M.


It might be my sound files. I think I trimed 1 file into 2 parts with LAME, but who knows how accurate that is.

Would you happen to know a method on how to preciousely cut 1 audio file into 2 gapless files?
Title: Command line gapless windows audio player?
Post by: AliL on 2008-08-05 00:20:07
I don't think you want to be using MP3 files as IIRC they cannot in themselves be gapless, and the players have to use some sort of workaround to make them gapless, like preloading the next song and starting it before the previous one has finished so that the audio is perfectly matched, but 2 files are actually playing at the same time at the point of crossover.

I'm pretty sure mp4/aac supports gapless playback as do most (all?) lossless formats, and they can be edited with Audacity.
Title: Command line gapless windows audio player?
Post by: tommedema on 2008-08-05 02:43:49
I don't think you want to be using MP3 files as IIRC they cannot in themselves be gapless, and the players have to use some sort of workaround to make them gapless, like preloading the next song and starting it before the previous one has finished so that the audio is perfectly matched, but 2 files are actually playing at the same time at the point of crossover.

I'm pretty sure mp4/aac supports gapless playback as do most (all?) lossless formats, and they can be edited with Audacity.


Hmm, so would it be possible to record in mp3 and then convert the recorded .wav to aac or an other lossless format? Or do I have to record to aac directly? Is that even possible?
Title: Command line gapless windows audio player?
Post by: ExUser on 2008-08-05 03:16:54
I don't think you want to be using MP3 files as IIRC they cannot in themselves be gapless, and the players have to use some sort of workaround to make them gapless, like preloading the next song and starting it before the previous one has finished so that the audio is perfectly matched, but 2 files are actually playing at the same time at the point of crossover.

I'm pretty sure mp4/aac supports gapless playback as do most (all?) lossless formats, and they can be edited with Audacity.
Please research your claims before making such assertions. Gapless MP3 playback in foobar2000 along with many other gapless MP3 players simply ensure that the tracks are of the proper length and do not require any kind of dual-file playback.
Title: Command line gapless windows audio player?
Post by: kornchild2002 on 2008-08-05 06:59:48
@spoon
thanks, I'd like to try that program out, but does it support gapless playback?


Let's go back and read their post:
As luck would have it, straight out of our R&B labs, we are releasing something tomorrow you will be interested in (no doubt), it will be billed as the most efficient (both memory and resources), gapless (and replaygian-able), multi zone audio player (designed to have as many as 10 simultaneous players running, including zones bridged together). Part 1 is done which the uPlayer which is controlled by the command line.


So yes, Spoon's solution will be gapless and it comes out tomorrow.  I will be interested to see what it is.
Title: Command line gapless windows audio player?
Post by: spoon on 2008-08-05 09:15:07
Quote
other gapless MP3 players simply ensure that the tracks are of the proper length and do not require any kind of dual-file playback.


Technically the 2nd track would have to be opened and read whilst there is data from the first track in the buffers. Doing the 2nd track when the first track had finished completely would limit the player to audio formats which are fast to decode. Also keeping the 1st stream open allows skipping back in the last second of playback (if a 1 second buffer was used).

>but does it support gapless playback?

Indeed, since R12 (of Music Converter) we have had sample perfect mp3 decoding.

Quote
I love that you have R&B labs.


You would not be far wrong with that statement
Title: Command line gapless windows audio player?
Post by: tommedema on 2008-08-05 13:14:02
Quote
other gapless MP3 players simply ensure that the tracks are of the proper length and do not require any kind of dual-file playback.


Technically the 2nd track would have to be opened and read whilst there is data from the first track in the buffers. Doing the 2nd track when the first track had finished completely would limit the player to audio formats which are fast to decode. Also keeping the 1st stream open allows skipping back in the last second of playback (if a 1 second buffer was used).

>but does it support gapless playback?

Indeed, since R12 (of Music Converter) we have had sample perfect mp3 decoding.

Quote
I love that you have R&B labs.


You would not be far wrong with that statement


Okay, so I guess I just have to wait for your program
Title: Command line gapless windows audio player?
Post by: spoon on 2008-08-05 13:15:14
Wait no longer:

http://www.hydrogenaudio.org/forums/index....showtopic=65107 (http://www.hydrogenaudio.org/forums/index.php?showtopic=65107)
Title: Command line gapless windows audio player?
Post by: tommedema on 2008-08-05 16:59:44
Wait no longer:

http://www.hydrogenaudio.org/forums/index....showtopic=65107 (http://www.hydrogenaudio.org/forums/index.php?showtopic=65107)


I'm not sure whether it is able to do what I want?
See http://www.hydrogenaudio.org/forums/index....id=581087&# (http://www.hydrogenaudio.org/forums/index.php?showtopic=65107&st=0&gopid=581087&#)
Title: Command line gapless windows audio player?
Post by: donnie on 2008-08-09 12:51:50
@donnie
I tried xmms2 but it does not seem to playback gapless either..

So no luck yet.. or you guys do manage to playback gapless? (without any sound disruption when it goes from file 1 to file 2)


I've just checked this myself and there is indeed an audible gap (about 20ms) when using xmms2 on a LAME encoded pair of mp3s. Sorry for the misinformation. I personally use mpd which is far more mature and definitely completely gapless on properly encoded mp3s (tested with audacity on Dark Side of the Moon)