[linux-audio-user] Lower Output Level after Mono to Stereo Conversion with SOX

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Martin McCormick <martin@xxxxxxxxxxxxxxxxxx>:

> 	I recorded a mono .wav file at 14400 samples per second and it
> sounds loud and clear.  Then, I got fancy and decided to convert it in
> to a stereo file suitable for putting on a CD.  It still sounds clear,
> but about 3DB down from the original mono recording.  

[...]

> 	I don't have any particular question about this script, but I
> do wonder why my mono/stereo conversion is a few DB down?

It's most likely a consequence of being run through a filter.  Remember,
filters generally REMOVE power rather than add it.  And even though you're
upsampling, some filtering is being done to eliminate synthetically created
aliasing noise.

You can always normalise the audio post-upsampling simply enough:

sox infile.wav -e stat -v

This will give you a recommended scaling value which won't cause clipping.

Then:

sox infile.wav outfile.wav -v ##.##

Inserting the value returned by the stat command into ##.##

Obviously, 1.0 means no scaling is needed.

This is all a linear adjustment, so +10dB boost = 10.0 scaling factor, and
+20dB = 100.0, etc.

I've scripted this in my application.

=MB=

-- 
A focus on Quality.


[Index of Archives]     [Linux Sound]     [ALSA Users]     [Pulse Audio]     [ALSA Devel]     [Sox Users]     [Linux Media]     [Kernel]     [Photo Sharing]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux