niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. |
| 3 | * |
| 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 |
| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 | |
kjellander | 3e6db23 | 2015-11-26 04:44:54 -0800 | [diff] [blame] | 11 | #ifndef WEBRTC_MODULES_AUDIO_CODING_TEST_SPATIALAUDIO_H_ |
| 12 | #define WEBRTC_MODULES_AUDIO_CODING_TEST_SPATIALAUDIO_H_ |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 13 | |
kwiberg | 3747838 | 2016-02-14 20:40:57 -0800 | [diff] [blame] | 14 | #include <memory> |
| 15 | |
kjellander | 3e6db23 | 2015-11-26 04:44:54 -0800 | [diff] [blame] | 16 | #include "webrtc/modules/audio_coding/include/audio_coding_module.h" |
| 17 | #include "webrtc/modules/audio_coding/test/ACMTest.h" |
| 18 | #include "webrtc/modules/audio_coding/test/Channel.h" |
| 19 | #include "webrtc/modules/audio_coding/test/PCMFile.h" |
| 20 | #include "webrtc/modules/audio_coding/test/utility.h" |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 21 | |
| 22 | #define MAX_FILE_NAME_LENGTH_BYTE 500 |
| 23 | |
tina.legrand@webrtc.org | 554ae1a | 2011-12-16 10:09:04 +0000 | [diff] [blame] | 24 | namespace webrtc { |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 25 | |
tina.legrand@webrtc.org | d5726a1 | 2013-05-03 07:34:12 +0000 | [diff] [blame] | 26 | class SpatialAudio : public ACMTest { |
| 27 | public: |
| 28 | SpatialAudio(int testMode); |
| 29 | ~SpatialAudio(); |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 30 | |
tina.legrand@webrtc.org | d5726a1 | 2013-05-03 07:34:12 +0000 | [diff] [blame] | 31 | void Perform(); |
| 32 | private: |
| 33 | int16_t Setup(); |
| 34 | void EncodeDecode(double leftPanning, double rightPanning); |
| 35 | void EncodeDecode(); |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 36 | |
kwiberg | 3747838 | 2016-02-14 20:40:57 -0800 | [diff] [blame] | 37 | std::unique_ptr<AudioCodingModule> _acmLeft; |
| 38 | std::unique_ptr<AudioCodingModule> _acmRight; |
| 39 | std::unique_ptr<AudioCodingModule> _acmReceiver; |
tina.legrand@webrtc.org | d5726a1 | 2013-05-03 07:34:12 +0000 | [diff] [blame] | 40 | Channel* _channel; |
| 41 | PCMFile _inFile; |
| 42 | PCMFile _outFile; |
| 43 | int _testMode; |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 44 | }; |
tina.legrand@webrtc.org | 554ae1a | 2011-12-16 10:09:04 +0000 | [diff] [blame] | 45 | |
tina.legrand@webrtc.org | d5726a1 | 2013-05-03 07:34:12 +0000 | [diff] [blame] | 46 | } // namespace webrtc |
tina.legrand@webrtc.org | 554ae1a | 2011-12-16 10:09:04 +0000 | [diff] [blame] | 47 | |
kjellander | 3e6db23 | 2015-11-26 04:44:54 -0800 | [diff] [blame] | 48 | #endif // WEBRTC_MODULES_AUDIO_CODING_TEST_SPATIALAUDIO_H_ |