Small refactoring of AudioProcessing use in channel.cc.

- Apply consistent naming.
- Use a scoped_ptr for rx_audioproc_.
- Remove now unnecessary AudioProcessing::Destroy().

R=bjornv@webrtc.org, xians@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/2184007

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4784 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
andrew@webrtc.org
2013-09-18 22:37:32 +00:00
parent 0d5da25e6c
commit f3930e941c
6 changed files with 81 additions and 135 deletions

View File

@ -105,8 +105,7 @@ class VoiceDetection;
// apm->Initialize();
//
// // Close the application...
// AudioProcessing::Destroy(apm);
// apm = NULL;
// delete apm;
//
class AudioProcessing : public Module {
public:
@ -118,11 +117,6 @@ class AudioProcessing : public Module {
static AudioProcessing* Create(int id);
virtual ~AudioProcessing() {}
// TODO(andrew): remove this method. We now allow users to delete instances
// directly, useful for scoped_ptr.
// Destroys a |apm| instance.
static void Destroy(AudioProcessing* apm);
// Initializes internal states, while retaining all user settings. This
// should be called before beginning to process a new audio stream. However,
// it is not necessary to call before processing the first stream after