Add support to audioproc_f to generate a custom call order file.

This adds a flag to audioproc_f to generate a custom call order
file from an AEC dump. This file can be used to get more realism
when simulating with wav-files.

Bug: webrtc:10393
Change-Id: I245533d18affaab2f6cef53138332d7d83c71822
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/126782
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Per Åhgren <peah@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27104}
This commit is contained in:
Ivo Creusen
2019-03-13 13:55:12 +01:00
committed by Commit Bot
parent f84b95dbec
commit 9a66d5ed65
5 changed files with 47 additions and 9 deletions

View File

@ -96,7 +96,8 @@ struct SimulationSettings {
bool print_aec_parameter_values = false;
bool dump_internal_data = false;
absl::optional<std::string> dump_internal_data_output_dir;
absl::optional<std::string> custom_call_order_filename;
absl::optional<std::string> call_order_input_filename;
absl::optional<std::string> call_order_output_filename;
absl::optional<std::string> aec_settings_filename;
};
@ -183,12 +184,14 @@ class AudioProcessingSimulator {
bool bitexact_output_ = true;
int aec_dump_mic_level_ = 0;
protected:
size_t output_reset_counter_ = 0;
private:
void SetupOutput();
size_t num_process_stream_calls_ = 0;
size_t num_reverse_process_stream_calls_ = 0;
size_t output_reset_counter_ = 0;
std::unique_ptr<ChannelBufferWavWriter> buffer_writer_;
std::unique_ptr<ChannelBufferWavWriter> reverse_buffer_writer_;
TickIntervalStats proc_time_;