OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 13 matching lines...) Expand all Loading... |
24 // into frequency bands inside the ChannelBuffer. The number of frames and | 24 // into frequency bands inside the ChannelBuffer. The number of frames and |
25 // channels must correspond to the constructor parameters. The same | 25 // channels must correspond to the constructor parameters. The same |
26 // ChannelBuffer can be passed in as |input| and |output|. | 26 // ChannelBuffer can be passed in as |input| and |output|. |
27 virtual void ProcessChunk(const ChannelBuffer<T>& input, | 27 virtual void ProcessChunk(const ChannelBuffer<T>& input, |
28 ChannelBuffer<T>* output) = 0; | 28 ChannelBuffer<T>* output) = 0; |
29 | 29 |
30 // Sample rate corresponds to the lower band. | 30 // Sample rate corresponds to the lower band. |
31 // Needs to be called before the the Beamformer can be used. | 31 // Needs to be called before the the Beamformer can be used. |
32 virtual void Initialize(int chunk_size_ms, int sample_rate_hz) = 0; | 32 virtual void Initialize(int chunk_size_ms, int sample_rate_hz) = 0; |
33 | 33 |
| 34 // Indicates whether a given point is inside of the beam. |
| 35 virtual bool IsInBeam(const SphericalPointf& spherical_point) { return true; } |
| 36 |
34 // Returns true if the current data contains the target signal. | 37 // Returns true if the current data contains the target signal. |
35 // Which signals are considered "targets" is implementation dependent. | 38 // Which signals are considered "targets" is implementation dependent. |
36 virtual bool is_target_present() = 0; | 39 virtual bool is_target_present() = 0; |
37 }; | 40 }; |
38 | 41 |
39 } // namespace webrtc | 42 } // namespace webrtc |
40 | 43 |
41 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_BEAMFORMER_BEAMFORMER_H_ | 44 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_BEAMFORMER_BEAMFORMER_H_ |
OLD | NEW |