MP3 Export Adding Garbage at Beginning

Effects, Recipes, Interfacing with other software, etc.
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
stats
Posts: 2
Joined: Sat Dec 04, 2010 4:43 pm
Operating System: Please select

MP3 Export Adding Garbage at Beginning

Post by stats » Sat Dec 04, 2010 4:51 pm

Hi,

I have Audacity 1.2.6 and version 3.98.3 of the lame encoder.

When I export a project as an MP3 0.1 seconds of silence is added to the beginning of the exported MP3 file.

This does not happen when I export as a WAV or export as an OGG file.

Is there a setting that I am missing that is adding extra bit to my MP3? This is a problem as I am trying to export a loop, and the 0.1 seconds of silence makes the loop sound choppy.

Image
Last edited by stats on Sat Dec 04, 2010 5:48 pm, edited 1 time in total.

stats
Posts: 2
Joined: Sat Dec 04, 2010 4:43 pm
Operating System: Please select

Re: MP3 Export Adding Garbage at Beginning

Post by stats » Sat Dec 04, 2010 5:05 pm

This is also happening in the 1.3 beta version. This leads me to believe that it is simply a lame problem.

I also tried lame versions 3.9.8.2 and the 4.0 beta, same issue with those as well.

I am still wondering if this is an issue that can be resolved, and if so how? It is really causing me a bit of a problem right now, and I am not sure how to work around it.

Irish
Forum Crew
Posts: 550
Joined: Sat Sep 05, 2009 9:25 pm
Operating System: Please select

Re: MP3 Export Adding Garbage at Beginning

Post by Irish » Sat Dec 04, 2010 6:07 pm

The silence at the beginning is a limitation of the MP3 format, so I'm afraid you're stuck with it.
Different versions of Lame or Audacity won't make it go away.

Why is it critical that you don't have silence at the beginning of the file? There may be other ways of working around the problem.

POL
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * Tips * * * * Tutorials * * * * 1.3 Quick Start Guide * * * * Audacity 1.3 Manual * * * * Audacity wiki * * * *

kozikowski
Forum Staff
Posts: 68902
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: MP3 Export Adding Garbage at Beginning

Post by kozikowski » Sat Dec 04, 2010 6:48 pm

Loops need to join perfectly beginning to end in order to sound right.

We tell people week after week that MP3 is a terrible format for audio production. the Frames and Gaps thing is only one of its problems. MP3 creates sound damage every time you use it.

MP3 is a final delivery or iPod format, not a production or mixing format.
It is a common audio format for consumer audio storage, as well as a de facto standard of digital audio compression for the transfer and playback of music on digital audio players.
--Wikipedia--

Not for production of new music.
...the basis of the MPEG Audio compression format (sampling rates, structure of frames, headers, number of samples per frame).
--Wikipedia--

It's the frames that kill you. It's not a continuous stream of music.

Koz

billw58
Forum Staff
Posts: 5565
Joined: Wed Aug 12, 2009 2:10 am
Operating System: macOS 10.15 Catalina or later

Re: MP3 Export Adding Garbage at Beginning

Post by billw58 » Sat Dec 04, 2010 8:24 pm

It is my understanding that the FFT algorithms used in MP3 encoding will produce "pre-echo". [MP3 is stored as information in the frequency domain, not the time domain] In order to properly reconstruct the first frame containing sound, it needs that pre-sound frame. But since that frame is there it decodes it too. If your sound starts a few milliseconds after the start of the track you won't notice this at all.

I believe if you zoom in on the start of your MP3, then zoom vertically (click in the vertical ruler) you will be able to see the pre-echo.

-- Bill

Irish
Forum Crew
Posts: 550
Joined: Sat Sep 05, 2009 9:25 pm
Operating System: Please select

Re: MP3 Export Adding Garbage at Beginning

Post by Irish » Sun Dec 05, 2010 11:01 am

stats wrote:This is a problem as I am trying to export a loop
Oops! Missed that bit. :oops:

POL
________________________________________FOR INSTANT HELP: (Click on Link below)
* * * * Tips * * * * Tutorials * * * * 1.3 Quick Start Guide * * * * Audacity 1.3 Manual * * * * Audacity wiki * * * *

yadurajiv
Posts: 3
Joined: Tue Dec 28, 2010 9:04 am
Operating System: Please select

Re: MP3 Export Adding Garbage at Beginning

Post by yadurajiv » Tue Dec 28, 2010 9:07 am

Ran into this problem just now as I was trying to convert a wav into an mp3 and loop it in a flash game.. So after a lot of searching I found a tool that takes my wave and throws out a looped mp3 - the site also has a proper explanation of how the program does it as well. Hope it helps

compuphase.com/mp3/mp3loops.htm

steve
Site Admin
Posts: 80677
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: MP3 Export Adding Garbage at Beginning

Post by steve » Tue Dec 28, 2010 8:27 pm

yadurajiv wrote:after a lot of searching I found a tool that takes my wave and throws out a looped mp3 - the site also has a proper explanation of how the program does it as well. Hope it helps
Unfortunately that does not help much at all.
The "prepared" MP3s suffer the same problem as any other MP3 which is that there is silence added to the beginning of the loop. This is unavoidable in the MP3 format.
The article itself is both confusing and misleading, containing such illuminating comments as;
it does something to the input file before the encoder transforms it to an MP3 file and it does something to the result after the encoder has completed running.
yet does not say what it does. As far as I can see, all it does is to minimise the added silence, but it does not solve the problem. The example file "Blues-Loop.mp3" clearly shows an additional 13 milliseconds of silence at the beginning of the file compared with the source file "Blues-Loop.wv".

The general impression given by this article is that the problem can be "easily fixed or circumvented", and if you don't fully understand how to do this then you need to hire their services.

Yes the problem is easily fixed - use a different format such as OGG or WAV. This solution does not require reading through a long confused article or hiring the services of its author.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

yadurajiv
Posts: 3
Joined: Tue Dec 28, 2010 9:04 am
Operating System: Please select

Re: MP3 Export Adding Garbage at Beginning

Post by yadurajiv » Sat Jan 08, 2011 1:20 pm

Well, I'm in no way promoting the person who wrote it. I just happened to find the article and thought it might help, not the article in itself, but the program provided(was for windows).

All I'm saying is that the software that the person had provided worked for me. If you have an option to use OGG or WAV over mp3 go for it!! I was stuck because I didn't know any other way to embed a WAV or OGG into my swf other than convert it into mp3.

yadurajiv
Posts: 3
Joined: Tue Dec 28, 2010 9:04 am
Operating System: Please select

Re: MP3 Export Adding Garbage at Beginning

Post by yadurajiv » Sat Jan 08, 2011 1:36 pm

ouch.. the silence is there.. But its hardly noticeable when I am playing the mp3 continuously in a loop, which is a bit weird.

Huge screenshot

Post Reply