OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
106 Beamforming() | 106 Beamforming() |
107 : enabled(false), | 107 : enabled(false), |
108 array_geometry() {} | 108 array_geometry() {} |
109 Beamforming(bool enabled, const std::vector<Point>& array_geometry) | 109 Beamforming(bool enabled, const std::vector<Point>& array_geometry) |
110 : enabled(enabled), | 110 : enabled(enabled), |
111 array_geometry(array_geometry) {} | 111 array_geometry(array_geometry) {} |
112 const bool enabled; | 112 const bool enabled; |
113 const std::vector<Point> array_geometry; | 113 const std::vector<Point> array_geometry; |
114 }; | 114 }; |
115 | 115 |
116 // Use to enable 48kHz support in audio processing. Must be provided through the | |
117 // constructor. It will have no impact if used with | |
118 // AudioProcessing::SetExtraOptions(). | |
119 struct AudioProcessing48kHzSupport { | |
120 AudioProcessing48kHzSupport() : enabled(true) {} | |
121 explicit AudioProcessing48kHzSupport(bool enabled) : enabled(enabled) {} | |
122 bool enabled; | |
123 }; | |
124 | |
125 static const int kAudioProcMaxNativeSampleRateHz = 32000; | 116 static const int kAudioProcMaxNativeSampleRateHz = 32000; |
126 | 117 |
127 // The Audio Processing Module (APM) provides a collection of voice processing | 118 // The Audio Processing Module (APM) provides a collection of voice processing |
128 // components designed for real-time communications software. | 119 // components designed for real-time communications software. |
129 // | 120 // |
130 // APM operates on two audio streams on a frame-by-frame basis. Frames of the | 121 // APM operates on two audio streams on a frame-by-frame basis. Frames of the |
131 // primary stream, on which all processing is applied, are passed to | 122 // primary stream, on which all processing is applied, are passed to |
132 // |ProcessStream()|. Frames of the reverse direction stream, which are used for | 123 // |ProcessStream()|. Frames of the reverse direction stream, which are used for |
133 // analysis by some components, are passed to |AnalyzeReverseStream()|. On the | 124 // analysis by some components, are passed to |AnalyzeReverseStream()|. On the |
134 // client-side, this will typically be the near-end (capture) and far-end | 125 // client-side, this will typically be the near-end (capture) and far-end |
(...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
787 // This does not impact the size of frames passed to |ProcessStream()|. | 778 // This does not impact the size of frames passed to |ProcessStream()|. |
788 virtual int set_frame_size_ms(int size) = 0; | 779 virtual int set_frame_size_ms(int size) = 0; |
789 virtual int frame_size_ms() const = 0; | 780 virtual int frame_size_ms() const = 0; |
790 | 781 |
791 protected: | 782 protected: |
792 virtual ~VoiceDetection() {} | 783 virtual ~VoiceDetection() {} |
793 }; | 784 }; |
794 } // namespace webrtc | 785 } // namespace webrtc |
795 | 786 |
796 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_INCLUDE_AUDIO_PROCESSING_H_ | 787 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_INCLUDE_AUDIO_PROCESSING_H_ |
OLD | NEW |