I have one or two .avi files for which the sound is simply too low. I like to play them in vlc, and enabling the graphic equalizer helps somewhat, but is there any other (easy and quick!) way of increasing the volume? Thanks!
- Start VirtualDub and load in your converted DivX file.
- From the "Video" menu, select "Direct Stream Copy".
- From the "Audio" menu, select "Full Processing Mode".
- From the "Audio" menu, select "Volume", check the "Adjust volume of audio channels" option, and you can use the slider to change the level of audio.
- Press the "Preview Output" button and listen to the audio - if it isn't loud enough, go back to the previous step and increase the amplification level.
- From the "Audio" menu, select "Compression" and select "MPEG Layer-3" and the same or lower bitrate/attributes (eg. 128 kBit/s, 48000 Hz, Stereo) you used earlier to make the DivX movie.
- From the "File" menu, select "Save AVI" to save the AVI to include the normalized audio. This shouldn't take too long as only the audio is re-encoded/compressed - the video will be left alone.
Very easy to do using ffmpeg:
For older versions of ffmpeg:
ffmpeg -i myvideo.avi -vcodec copy -acodec libmp3lame -ab 128k -vol 5000 myvideo_louder.avi
Adjust the "-vol" parameter until you're satisfied with the volume.
While you're looking for the appropriate "-vol" value, I suggest you add a "-t 30" to your commandline, so it'll only process the first 30s of video. It's much faster and should be enough for you to evaluate the results.
The new versions of ffmpeg support audio filters (-af), so you may alter volume using the volume filter which accepts volume gain specified in dB:
ffmpeg -i inputfile -vcodec copy -af "volume=-20dB" outputfile
Look at this question: How to amplify the audio in a video file?
Quoted answer by Davy Landman:
You'll need to do this in following steps.
- Demux (extract) the audio stream from the container, depending on your container you should use the correct application. For a general purpose demuxer you could use ffmpeg. But there are more user friendly programs such as VirtualDub for avi, TMPGEnc for mpg files.
- Decode the audio to a wave file (not always needed if Audacity can open the file directly)
- Increase the volume of your audio track using Audacity by gaining your audio file such as described in the first step in this howto.
- Save the result as a wave file.
- Encode the wave file using the right tool for your desired audio coded (lame for mp3, faac for aac)
- Remux the new audio and original video tracks back into the desired container using the same program you used for demuxing.
If input file contain multiple streams you can use
-map parameter of ffmpeg along with
ffmpeg -i inputfile -map 0:v -map 0:a -vol 1024 outputfile
Note that -vol 256 is equal to unchanged