I have about 500 wma files for which I need to increase the volume.
These are on a USB stick in my auto, but the volume when they play is way less than when the sound system is set to AM, FM, or CD. It is possibly just a bad implementation of amp gain in the automobile software, but nevertheless, I would like to not have to make fairly major level changes when switching between AUX and one of the other sound functions.
Is this possible in Audacity? I have used it in the past to change the level of one or two files, but it would take forever to do it on 500, one at a time.
Also, I don’t know how much to do the increase if it is possible (other than trial and error).
I’ve never done this myself, but you should be able to use [u]batch processing[/u].
Now… There are a couple of issues…
1. If these are commercial recordings, most of them are already normalized (maximized). If so, you can’t boost the volume without (potentially) clipping (distorting).
The peak levels determine the maximum, but the peaks don’t correlate well with “loudness” You’ll find lots of quiet-sounding files that are normalized. You can normalize all of your files to maximize the volumes, but they will not sound equally-loud.
If you open a few of the files in Audacity and run the Amplify effect, the Amplify effect will scan the file and then default to whatever maximum gain boost you can get without clipping. That’s a quick way to check if the volume can be increased. And, if you just run Amplify and use the default, your files will be normalized/maximized. You should be able to do that in an automated batch process.
I’m not 100% sure if WMA is limited to 0dBFS (AKA 1.0 or 100%), but your digital-to-analog converter is, and/or a WMA file that goes over 0dB may get clipped when it’s decompressed for playback.
2. WMA (like MP3 and AAC) is lossy compression. When you edit a compressed file with any normal audio editor it has to be de-compressed first. If you re-save (export) to WMA, you are going through a 2nd lossy-compression step. You may not notice any quality loss, but it’s something you should be aware of.
Thanks. I will have to study those a bit.
are the commands in the EDit Chains discussion what I would use,
except line 2 would be
How do you make it apply recursively to all 500 files?
You can’t use Chains for this - there is no ExportWMA command. It’s a feature request that there should be Chain Export commands for FFmpeg formats.
Try dBPowerAmp instead. Add the WMA codec to it from their “Codec Central” page. dBPowerAmp can batch process. Apply “Volume Normalize” with ReplayGain instead of Peak to Peak. ReplayGain will make a better job of making the files sound equally loud.
The files to be affected all have to be in the same folder. Audacity can’t look inside other folders.
I want to digress a moment here as something just occurred to me…
As I understand it, the ‘normalize’ function sets the amplitude of the loudest peak to a level that will not clip. But I do not see how it can do that as that clipping point would vary depending on what device the file was being played!
So what is wrong with my thinking here?
By default, Normalize amplifies the selected audio so that the peak level is -1.0 dB (http://manual.audacityteam.org/o/man/normalize.html)
Audio will clip at 0 dB*, so by default the Normalize effect allows a little headroom.
*Note that in practice, sound cards may clip slightly below peak sample values of 0 dB, and that “lossy formats” (such as MP3 or WMA), the encoded waveform may be a little higher than the original waveform, so for highest quality it is best to allow a little headroom.
When processing files individually, or in a Chain (which process files one at a time in sequence), the Normalize effects looks at the current peak level of the track, then calculates how much to amplify by so as to achieve the desired peak amplitude for that track, then applies that amount of amplification. Thus, each track will end up with the same peak amplitude.
Note that “peak amplitude” is not the same as “loudness”. Tracks in which the waveform is more “dense” will tend to be louder than tracks where the waveform looks more sparse, even if both have the same peak amplitude.
That is a great explanation, but there is an aspect I am still not grasping.
Do not the samples create a SPECIFIC amplitude, and could not any given amplitude sound louder in one device than in some other.
For example, say a pure sinewave tone is digitized and normalized. Could that file not sound different volume when played on two different brands of CD players with the amp set at the same volume position (D to A happening in the CD player)?
CD players are usually fairly consistent (-10 dBV out for a 0 dB signal), but I get your point, and yes, different devices may well produce different levels of output from the same signal.
I am really learning a lot with this…
Is “0 db” equivalent to all bits in the digitized sample being set 1?
In other words no sample could ever be higher than “0 db?”
Its “dB” with upper case “B”.
Sample values can be positive or negative and the possible values increase with bit depth.
For 16-bit depth the minimum value = 0 000 000 000 000 000 = 0 (decimal) and the maximum value = 1 111 111 111 111 111 = 65535 (decimal).
So for 16-bit the number of discrete values above or below zero linear (silence) = 32767, and +32767 is the same as +1 linear and -32767 is the same as -1 linear. I’m not getting into the argument whether the values are really -32768 to +32767 and there is no representation of zero.
For 24-bit data there are 16777216 discrete values.
In 32-bit float format sample values are not restricted to whole numbers and sample values above 0 dB can be represented (but will still probably distort in almost all playback equipment).
I am not a mathematician so I bow out gracefully now.
[Update: I see that Gale has replied while I was typing, so this is basically the same answer in different words ]
0 dB is equivalent to any sample having a value of +/- 1
This rather strange looking waveform has a peak amplitude of 0 dB, because the most extreme peaks (peaks can go down as well as up) are at -1.0
“Peak amplitude” is one common measure of the “vertical size” of a waveform. Another commonly used measure is “rms”, which is a kind of “average vertical size”.
For most commonly used audio formats, 0 dB is the absolute minimum or maximum value possible. This is because most commonly used audio formats use integers (whole numbers). For example, for “signed 16 bit audio”, each sample has a numerical value between -32768 and 32767 (binary values 000 000 000 000 000 and 111 111 111 111 111).
The numerical value is then divided by 32768 to give a sample value in the range of -1 to +1.
By default, Audacity uses “32 bit float format”. This has two major advantages:
- There are lots of “bits”, so calculations can be performed extremely precisely.
- “float format” can represent numbers greater than 0 dB. This means that if you inadvertently cause the waveform to exceed 0 dB while working on it (which will cause clipping on playback because all sound cards use integer format), you can recover from it by “amplifying” (Amplify or Normalize effects) back down to the valid range below 0 dB. Note: This only works if the track is in 32 bit float format. For Integer format tracks, exceeding 0 dB causes permanent damage.
Probably a bit more than you asked for, but does that answer your question?
Well, got around to starting this project today, and discovered the need for FFmpeg plugin for Audacity to do wma. No problem—just install it.
But the first few files I opened showed amplification needed of NEGATIVE numbers (like -0.1, -0.3)–which I assume means they are already pretty much at max volume.
Which leads me to reluctantly conclude that it is the gain setting of that AUX (USB port) function in the car ‘radio’ that is just bunged up–being substantially lower than the other functions. I can’t tell you how disappointing this is as it is in a slightly premium car (Avalon); you’d think they would be able to get simple things right.
Bottom line: no solution.