Re: [AUDITORY] Converting audio file from WAV to MP3 changes file duration. Why? (James Johnston )


Subject: Re: [AUDITORY] Converting audio file from WAV to MP3 changes file duration. Why?
From:    James Johnston  <audioskeptic@xxxxxxxx>
Date:    Tue, 14 Nov 2017 23:47:45 -0800
List-Archive:<http://lists.mcgill.ca/scripts/wa.exe?LIST=AUDITORY>

--94eb2c05a3b024741d055e00b874 Content-Type: text/plain; charset="UTF-8" mp3 carrier format will round up to the next block size. This was discussed before in committee. Sadly, it happened anyhow. On Tue, Nov 14, 2017 at 11:02 PM, Neeraj Sharma <neerajww@xxxxxxxx> wrote: > Dear Members, > > An audio file in WAV can be converted to MP3 using following two utilities > in unix terminal (both work, and there may be many more also): > > $ ffmpeg -i <input.wav> -codec:a libmp3lame -b:a 320k <output.mp3> > </dev/null > $ lame -q0 -b128 <input.wav> <output.wav> > > But the issue is that the duration of <output.mp3> is more than duration > of <input.wav>. This is true with other utilities which I have tried, like > sox. Can anyone give insight on: > > a. why the duration is increasing? In the attached image below, the > duration variation is plotted for 410 sound files. The increase in duration > appears to be WAV file dependent (although it is within 140ms in this case) > > b. is there option in the above utilities which can reduce this difference > in duration? I haven't been able to figure this out. > > Similar issue has been reported by few others also. > Example: https://www.sweetwater.com/forums/showthread.php?42631 > > Best regards, > Neeks > > > -- James D. (jj) Johnston Independent Audio and Electroacoustics Consultant --94eb2c05a3b024741d055e00b874 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>mp3 carrier format will round up to the next block si= ze.<br><br></div>This was discussed before in committee. Sadly, it happened= anyhow.<br></div><div class=3D"gmail_extra"><br><div class=3D"gmail_quote"= >On Tue, Nov 14, 2017 at 11:02 PM, Neeraj Sharma <span dir=3D"ltr">&lt;<a h= ref=3D"mailto:neerajww@xxxxxxxx" target=3D"_blank">neerajww@xxxxxxxx</a>&= gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margin:0 0 = 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=3D"ltr">Dear M= embers,<br><br>An audio file in WAV can be converted to MP3 using following= two utilities in unix terminal (both work, and there may be many more also= ):<br><br>$ ffmpeg -i &lt;input.wav&gt; -codec:a libmp3lame -b:a 320k &lt;o= utput.mp3&gt; &lt;/dev/null<br>$ lame -q0 -b128 &lt;input.wav&gt; &lt;outpu= t.wav&gt;<br><br>But the issue is that the duration of &lt;output.mp3&gt; i= s more than duration of &lt;input.wav&gt;. This is true with other utilitie= s which I have tried, like sox. Can anyone give insight on:<br><br><div>a. = why the duration is increasing? In the attached image below, the duration v= ariation is plotted for 410 sound files. The increase in duration appears t= o be WAV file dependent (although it is within 140ms in this case)<br><br><= div>b. is there option in the above utilities which can reduce this differe= nce in duration?=C2=A0 I haven&#39;t been able to figure this out.<br><br>S= imilar issue has been reported by few others also.<br>Example: <a href=3D"h= ttps://www.sweetwater.com/forums/showthread.php?42631" target=3D"_blank">ht= tps://www.sweetwater.com/<wbr>forums/showthread.php?42631</a><br><br>Best r= egards,<br>Neeks<div><br></div><div><br></div></div></div></div> </blockquote></div><br><br clear=3D"all"><br>-- <br><div class=3D"gmail_sig= nature" data-smartmail=3D"gmail_signature"><div>James D. (jj) Johnston</div= ><div>Independent Audio and Electroacoustics Consultant</div></div> </div> --94eb2c05a3b024741d055e00b874--


This message came from the mail archive
../postings/2017/
maintained by:
DAn Ellis <dpwe@ee.columbia.edu>
Electrical Engineering Dept., Columbia University