Noise reduction

I wish to carve out a Noise reduction code from the existing Audacity code. But given the complex interdendancy in audacity code I am finding it difficult to separate only Noise reduction part of audacity. Can anyone suggest the best way of achieving this objective.

Ideally, what I want is a noise reduction API.


Have you actually used Noise Reduction? It’s not convenient because of the two-step process. It’s not a one-pass tool which is what it sounds like you’re looking for.


That two-step thing may be why it seems so complicated in code. It’s actually a mini-dialog with the user. It has to ask for and then store sound values, and only then do the reduction based on even more user input.

I have a program called SoundSoap which does I think what you’re after. It assumes the global, overall noise in the whole show is what you want to reduce and uses that for the reduction. It’s not nearly as effective as the two-step process.


Thanks Koz for your reply.

Koz, What I want to achieve is to create two funtions namely. 1] CreateNoiseProfile(sound.wav , duration) which will output NoiseFile.profile and 2] ReduceNoise(Sound.wav, NoiseFile.profile) which will output NoiseReduced.wav

But given the strong interdependence among the program files I am finding it difficult to separate out the relevant portion of the code. Any leads as to how to proceed.


Look in src/effects/NoiseReduction.cpp

Noise Reduction uses RealFFTf (in RealFFTf.cpp) and either does EffectNoiseReduction::Worker::GatherStatistics or EffectNoiseReduction::Worker::ReduceNoise depending on whether it is creating a noise profile or applying the profile (to reduce or isolate the noise).