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 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 ExperimentalNs() : enabled(false) {} | 102 ExperimentalNs() : enabled(false) {} |
103 explicit ExperimentalNs(bool enabled) : enabled(enabled) {} | 103 explicit ExperimentalNs(bool enabled) : enabled(enabled) {} |
104 bool enabled; | 104 bool enabled; |
105 }; | 105 }; |
106 | 106 |
107 // Use to enable beamforming. Must be provided through the constructor. It will | 107 // Use to enable beamforming. Must be provided through the constructor. It will |
108 // have no impact if used with AudioProcessing::SetExtraOptions(). | 108 // have no impact if used with AudioProcessing::SetExtraOptions(). |
109 struct Beamforming { | 109 struct Beamforming { |
110 Beamforming() | 110 Beamforming() |
111 : enabled(false), | 111 : enabled(false), |
112 array_geometry() {} | 112 array_geometry(), |
| 113 target_direction(SphericalPointf(M_PI / 2.f, 0.f, 1.f)) {} |
113 Beamforming(bool enabled, const std::vector<Point>& array_geometry) | 114 Beamforming(bool enabled, const std::vector<Point>& array_geometry) |
| 115 : Beamforming(enabled, |
| 116 array_geometry, |
| 117 SphericalPointf(M_PI / 2.f, 0.f, 1.f)) {} |
| 118 Beamforming(bool enabled, |
| 119 const std::vector<Point>& array_geometry, |
| 120 SphericalPointf target_direction) |
114 : enabled(enabled), | 121 : enabled(enabled), |
115 array_geometry(array_geometry) {} | 122 array_geometry(array_geometry), |
| 123 target_direction(target_direction) {} |
116 const bool enabled; | 124 const bool enabled; |
117 const std::vector<Point> array_geometry; | 125 const std::vector<Point> array_geometry; |
| 126 const SphericalPointf target_direction; |
118 }; | 127 }; |
119 | 128 |
120 // Use to enable intelligibility enhancer in audio processing. Must be provided | 129 // Use to enable intelligibility enhancer in audio processing. Must be provided |
121 // though the constructor. It will have no impact if used with | 130 // though the constructor. It will have no impact if used with |
122 // AudioProcessing::SetExtraOptions(). | 131 // AudioProcessing::SetExtraOptions(). |
123 // | 132 // |
124 // Note: If enabled and the reverse stream has more than one output channel, | 133 // Note: If enabled and the reverse stream has more than one output channel, |
125 // the reverse stream will become an upmixed mono signal. | 134 // the reverse stream will become an upmixed mono signal. |
126 struct Intelligibility { | 135 struct Intelligibility { |
127 Intelligibility() : enabled(false) {} | 136 Intelligibility() : enabled(false) {} |
(...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
929 // This does not impact the size of frames passed to |ProcessStream()|. | 938 // This does not impact the size of frames passed to |ProcessStream()|. |
930 virtual int set_frame_size_ms(int size) = 0; | 939 virtual int set_frame_size_ms(int size) = 0; |
931 virtual int frame_size_ms() const = 0; | 940 virtual int frame_size_ms() const = 0; |
932 | 941 |
933 protected: | 942 protected: |
934 virtual ~VoiceDetection() {} | 943 virtual ~VoiceDetection() {} |
935 }; | 944 }; |
936 } // namespace webrtc | 945 } // namespace webrtc |
937 | 946 |
938 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_INCLUDE_AUDIO_PROCESSING_H_ | 947 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_INCLUDE_AUDIO_PROCESSING_H_ |
OLD | NEW |