Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Mp4 isn't gapless too? (Read 5152 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Mp4 isn't gapless too?

I encoded some tracks with the Nero plug-in and when I decoded with Winamp, all of the resulting wav files were some kilobytes smaller than the original wavs and they didn't play gapless accurately. Why is this happening? Is it like mp3, which is not gapless?


Mp4 isn't gapless too?

Reply #2
Quote
for proper gapless output in winamp, use one of these two plugins
Gapless Output v0.7.2
MP3splice Gapless Output

let me know if it fixes it

My main concern is the fact that the decoded wavs are not identical in size with the original ones.

edit: the latest DirectSound output plug-in plays perfectly gapless with ogg and cd audio, so it must the mp4 

Mp4 isn't gapless too?

Reply #3
Quote
the latest DirectSound output plug-in plays perfectly gapless with ogg and cd audio, so it must the mp4

I cant see why it wouldnt.  The gaplessness of playback is not related to the input filetype.  But yes, with lossy codecs almost always there is a slight change in length.

Mp4 isn't gapless too?

Reply #4
mp4 is not gapless
length is the same with gapless fileformat (mpc, vorbis)
mp3splice doesn't provide perfect gapless playback, at least with mp4 (ahead codec)

Take a look at this thread :
http://www.hydrogenaudio.org/forums/index....91&hl=minkowski

Mp4 isn't gapless too?

Reply #5
jesseg:

Quote
The gaplessness of playback is not related to the input filetype.


This is incorrect. Unless you're using something like MP3Splice which "hacks" the gaps out of the files, the ability to playback gaplessly depends mainly on whether the input format supports gapless encoding/decoding. MP3 and AAC obviously don't, while Ogg Vorbis and MPC do.

Of course, the player needs to perform proper buffering to actually take advantage of gapless formats, but that isn't a problem with Winamp 2.81 (+correctly configured WaveOut/DirectSound plugin) and foobar2000. So, provided you're using a proper player, gapless playback is solely dependant on the audio format used.

Mp4 isn't gapless too?

Reply #6
Volcano, your post contridicts itself by saying its only an input thing, yet you prove that you need to have proper output software to get true gapless playback....

This is true even for wav files, and I know that AAC changes the length of the file.  I wasnt aware that mpc and ogg didnt though, that's cool.

j

Mp4 isn't gapless too?

Reply #7
Quote
Take a look at this thread :
http://www.hydrogenaudio.org/forums/index....91&hl=minkowski

Or at this one: 
http://www.audiocoding.com/phorum/read.php...f=1&i=744&t=743

So this question is at least more than one year old, and Menno did not follow that idea he mentioned there yet. Maybe because this feature wasn't questioned by other users or perhaps because he found difficulties with that "hacker" approach afterwards.*

As I mentioned in the other thread, the proper "gaplessness" of any content in the MPEG-4 standard is probably handled by the Scene Description (BIFS) which is a binary stream itself within the MP4 container besides other elementary streams like audio or video content. As long as an AAC encoder does not provide these Scene Descriptions in a MP4 container, there's of course no chance for a MP4 decoder to use them (the field "BIFS" can already be seen in a MP4 header though).

I don't know what QuickTime 6 Pro does when you encode a MP4 "movie" with it, but maybe there are already solutions for this problem, because Apple/QuickTime is also exploring the MPEG-4 possibilities for streaming live content over the internet, and there you'll certainly need an answer to this "gapless" question. The MPEG4IP project does the same, so maybe a MPEG-4 compatible solution could also come from them.

*Edit:
OK, here's the reason why MPEG-2 AAC can't be gapless in the normal sense of the term (only full blocks of 1024 samples are possible during encoding):
http://www.hydrogenaudio.org/forums/index....=ST&f=13&t=2285

This also explains why sometimes you get better results (when a file length comes close to this limit) and sometimes you don't with usual players and/or additional "gapless" plugins.

This is also due to the ADTS or ADIF headers that have to precede every frame or at least the beginning of a new file in a MPEG-2 AAC bitstream. In the MP4 container those headers are gone (= raw AAC bitstream), and the additional side information (like "subtracks" of a long file without gaps) is supposed to be handled by the Scene Description.
ZZee ya, Hans-Jürgen
BLUEZZ BASTARDZZ - "That lil' ol' ZZ Top cover band from Hamburg..."
INDIGO ROCKS - "Down home rockin' blues. Tasty as strudel."

Mp4 isn't gapless too?

Reply #8
Quote
Volcano, your post contridicts itself by saying its only an input thing, yet you prove that you need to have proper output software to get true gapless playback....

This is true even for wav files, and I know that AAC changes the length of the file.  I wasnt aware that mpc and ogg didnt though, that's cool.

j

You don't need proper output plug-ins for gapless playback. You only need to buffer the start of the next song, so as to play it the exact moment the previous song finishes. Older Winamp output plug-ins were introducing a pause between songs because of stupid Winamp architecture, but PP used hacks in order to have gapless playback. So, I believe that if the format played does not alter the length of the file, then any(?) well-designed player can have gapless playback. Ogg and Mpc do not alter the song length, that's why I use ogg.

Mp4 isn't gapless too?

Reply #9
Cool, I use mpc/aac.  :alien:

Mp4 isn't gapless too?

Reply #10
[span style='font-size:8pt;line-height:100%'][EDIT][/span] Oops, I hadn't realized you had already replied after Wizard's post... (wrote the msg offline and didn't refresh the thread...) [span style='font-size:8pt;line-height:100%'][/EDIT][/span]

Quote
jesseg wrote:
Volcano, your post contridicts itself by saying its only an input thing, yet you prove that you need to have proper output software to get true gapless playback....




1) MP3 and AAC introduce silence at the beginning and at the end of the file as a result of the encoding/decoding process. The silence is actually in the file.
2) Vorbis and MPC don't.

Thus, Vorbis and MPC can be played back gaplessly by any player that switches tracks without any delay (which is how it should be), while you would need a program that "hacks" leading and trailing silence out of MP3 and AAC files to play them gaplessly.

Probably Wizard's explanation is 100 times easier to understand than this, but oh well

Mp4 isn't gapless too?

Reply #11
Vorbis and MPC DO add silence.
But the container stores the padding value in order to remove it on playback.

Mp4 isn't gapless too?

Reply #12
Quote
Vorbis and MPC DO add silence.
But the container stores the padding value in order to remove it on playback.

I didn't know that, thanks B) So, can't this be done for mp4? mp4 is the container for aac, am I right?