IPB

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
Does mp3 convert to WAV losslessly?, Title is the question
Gainless
post Mar 28 2012, 20:38
Post #1





Group: Members
Posts: 173
Joined: 28-October 11
Member No.: 94764



I just wondered if this the case, because actually the Mp3 format is using a lot of of overdrives which is not possible in a WAV file. So if I e.g. make an audio CD with some Mp3's, will they remain exactly the same or will they differ from what an audio player would decode?
Go to the top of the page
+Quote Post
pdq
post Mar 28 2012, 20:49
Post #2





Group: Members
Posts: 3450
Joined: 1-September 05
From: SE Pennsylvania
Member No.: 24233



Different mp3 decoders, if they are working correctly, will produce nearly bit identical PCM data, whether you play it directly or first record it to a CD. It is possible, however, for a player to decode to something with a greater dynamic range than 16 bit audio and the rescale it to avoid clipping.
Go to the top of the page
+Quote Post
saratoga
post Mar 28 2012, 20:59
Post #3





Group: Members
Posts: 5147
Joined: 2-September 02
Member No.: 3264



QUOTE (Gainless @ Mar 28 2012, 15:38) *
I just wondered if this the case, because actually the Mp3 format is using a lot of of overdrives which is not possible in a WAV file. So if I e.g. make an audio CD with some Mp3's, will they remain exactly the same or will they differ from what an audio player would decode?


The spec requires a specific accuracy from all decoders, but beyond that a small amount of error will be present since mp3 decoding is essentially an approximate process. The spec ensures that the error added by the decoder is orders of magnitude smaller then the error added by the encoder, so in practice it doesn't matter unless the decoder is badly broken.
Go to the top of the page
+Quote Post
stephan_g
post Apr 5 2012, 16:56
Post #4





Group: Members
Posts: 220
Joined: 6-June 10
From: Bavaria
Member No.: 81240



I think what the OP wanted to know was: If the MP3 decodes to something with higher-than-fullscale peak amplitudes, what happens?

Answer: If you decode straight into 16-bit PCM, anything beyond fullscale gets clipped.

If you want to avoid that, you'll need a decoder with the necessary headroom and some additional processing to reduce levels before converting into 16-bit PCM (with dithering, yadda yadda) - exactly like a "proper" playback chain. How you achieve that is up to you. I might use Foobar2000's converter with Replaygain mode set to either "prevent clipping" or "apply gain, prevent clipping", assuming the files in question are RG scanned.

This post has been edited by stephan_g: Apr 5 2012, 16:58
Go to the top of the page
+Quote Post
mjb2006
post Apr 7 2012, 05:21
Post #5





Group: Members
Posts: 859
Joined: 12-May 06
From: Colorado, USA
Member No.: 30694



Couldn't you just apply ReplayGain, using the minimum gain reduction needed to avoid clipping? What would be lost?
Go to the top of the page
+Quote Post
Gainless
post Apr 8 2012, 00:15
Post #6





Group: Members
Posts: 173
Joined: 28-October 11
Member No.: 94764



Well, to bring it to the point: Is it possible to do a bit-exact conversion of an mp3 to a WAV file?
If I understood the previous posters right it's not due to the high peaks of an mp3 file...
Go to the top of the page
+Quote Post
saratoga
post Apr 8 2012, 00:36
Post #7





Group: Members
Posts: 5147
Joined: 2-September 02
Member No.: 3264



QUOTE (Gainless @ Apr 7 2012, 19:15) *
Well, to bring it to the point: Is it possible to do a bit-exact conversion of an mp3 to a WAV file?


As I said before, decoding is an approximate process. There is nothing to be "bit-exact" in comparison to.

QUOTE (Gainless @ Apr 7 2012, 19:15) *
If I understood the previous posters right it's not due to the high peaks of an mp3 file...


Yes, peaks are not really related to MP3, they're more generally a question of how DSP operations are implemented on computers. Any lossy process can introduce above full-scale peaks, and any well implemented DSP process can handle them by using proper precision and/or scaling. MP3 is no different. The player on your CD player could screw it up, or the player on your computer could screw it up. If in doubt, you can always add a dB or two of EQ precut or use replaygain to avoid this whole problem.
Go to the top of the page
+Quote Post
frenzic
post Apr 8 2012, 03:35
Post #8





Group: Members
Posts: 13
Joined: 29-March 12
Member No.: 98191



to the op

the fraunhofer institute has something called mp3hd specs:

* mp3HD is a lossless audio codec (100% bit-exact replica of CD tracks)
* Backward compatible to mp3
* File extension .mp3
* Bitrates for music approximately 500 to 900 kbit/s rates (similar to other lossless codecs), depending on genre
* Embedded mp3 track and the mp3HD file share the same id3 metadata

http://www.iis.fraunhofer.de/en/bf/amm/pro...iocodecs/mp3hd/

so yeah. Edit: But only if you use that particular fraunhofer codec.

You can get the tools here:
http://www.all4mp3.com/tools/mp3HD-tools.php

This post has been edited by frenzic: Apr 8 2012, 03:41
Go to the top of the page
+Quote Post
lvqcl
post Apr 8 2012, 09:47
Post #9





Group: Developer
Posts: 3461
Joined: 2-December 07
Member No.: 49183



Can you losslessly convert sqrt(2) to a real number?
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 17th December 2014 - 23:09