views:

43

answers:

1

Hi,

I'm a little confused with an issue that I keep running into. I'm trying to create some sound loops for continuously playing, seamless background music.. everything's fine as long as I stay in AAC/ WAV/ etc, but as soon as I encode the files in AAC I run into a 1/10 of a second at end of the sound file.

I'm on the Mac, so I've tried encoding with iTunes, Compressor (included in Final Cut Pro), Adobe Soundbooth and finally Audacity. I keep getting that stupid 1/10 gap at the end of the track.

Is this something inherent in AAC encoding.. does the last package/frame/whatever-the-right-term-is have to be silent?

Any idea on how I can encode a sound file in AAC without getting that gap at the end?

Any help would be very much appreciated.

A: 

This is somewhat inherent to MP3 because "blocks" of the same length are written to the files instead of allowing to define the length of a block (like OGG/Vorbis does, for example). LAME seems to have a "gapless" feature that allows MP3 files of exact length.

If understand the information on the Internet correctly (this hydrogenaudio.org forum entry for example, AAC suffers from the same problem and there seems to be a gapless tag that same encoders are able to set. In the provided link, it is said that a recent version of iTunes+Quicktime can insert such tags.

AndiDog
Thanks. I'm very new to audio encoding stuff and didn't know about such restrictions. I'm doing this using audio queue services to eliminate playback gaps inherent in NSSound, but I'd be very surprised if that API respects the gapless tags produced by iTunes as you are working with more or less raw data. Anyway, I can stop wasting my time trying to encode the files without a gap at the end, since it seems inherent. I'll just use aiff for the loops where the gap is a real problem. Thanks for the help.
Frank R.