2011-08-03 21:08:51 +00:00
|
|
|
syntax = "proto2";
|
|
|
|
|
option optimize_for = LITE_RUNTIME;
|
|
|
|
|
package webrtc.audioproc;
|
|
|
|
|
|
2015-10-03 00:39:14 +02:00
|
|
|
// Contains the format of input/output/reverse audio. An Init message is added
|
|
|
|
|
// when any of the fields are changed.
|
2011-08-03 21:08:51 +00:00
|
|
|
message Init {
|
|
|
|
|
optional int32 sample_rate = 1;
|
2014-04-22 21:00:04 +00:00
|
|
|
optional int32 device_sample_rate = 2 [deprecated=true];
|
2011-08-03 21:08:51 +00:00
|
|
|
optional int32 num_input_channels = 3;
|
|
|
|
|
optional int32 num_output_channels = 4;
|
|
|
|
|
optional int32 num_reverse_channels = 5;
|
2014-03-10 22:26:12 +00:00
|
|
|
optional int32 reverse_sample_rate = 6;
|
2014-04-22 21:00:04 +00:00
|
|
|
optional int32 output_sample_rate = 7;
|
2016-04-11 07:05:53 -07:00
|
|
|
optional int32 reverse_output_sample_rate = 8;
|
|
|
|
|
optional int32 num_reverse_output_channels = 9;
|
2018-08-10 15:38:52 +02:00
|
|
|
optional int64 timestamp_ms = 10;
|
2011-08-03 21:08:51 +00:00
|
|
|
}
|
|
|
|
|
|
2014-03-04 20:58:13 +00:00
|
|
|
// May contain interleaved or deinterleaved data, but don't store both formats.
|
2011-08-03 21:08:51 +00:00
|
|
|
message ReverseStream {
|
2014-03-04 20:58:13 +00:00
|
|
|
// int16 interleaved data.
|
2011-08-03 21:08:51 +00:00
|
|
|
optional bytes data = 1;
|
2014-03-04 20:58:13 +00:00
|
|
|
|
|
|
|
|
// float deinterleaved data, where each repeated element points to a single
|
|
|
|
|
// channel buffer of data.
|
|
|
|
|
repeated bytes channel = 2;
|
2011-08-03 21:08:51 +00:00
|
|
|
}
|
|
|
|
|
|
2014-03-04 20:58:13 +00:00
|
|
|
// May contain interleaved or deinterleaved data, but don't store both formats.
|
2011-08-03 21:08:51 +00:00
|
|
|
message Stream {
|
2014-03-04 20:58:13 +00:00
|
|
|
// int16 interleaved data.
|
2011-08-03 21:08:51 +00:00
|
|
|
optional bytes input_data = 1;
|
|
|
|
|
optional bytes output_data = 2;
|
2014-03-04 20:58:13 +00:00
|
|
|
|
2011-08-03 21:08:51 +00:00
|
|
|
optional int32 delay = 3;
|
|
|
|
|
optional sint32 drift = 4;
|
2022-09-05 16:05:24 +02:00
|
|
|
optional int32 applied_input_volume = 5;
|
2014-02-12 15:28:30 +00:00
|
|
|
optional bool keypress = 6;
|
2014-03-04 20:58:13 +00:00
|
|
|
|
|
|
|
|
// float deinterleaved data, where each repeated element points to a single
|
|
|
|
|
// channel buffer of data.
|
|
|
|
|
repeated bytes input_channel = 7;
|
|
|
|
|
repeated bytes output_channel = 8;
|
2011-08-03 21:08:51 +00:00
|
|
|
}
|
|
|
|
|
|
2015-10-03 00:39:14 +02:00
|
|
|
// Contains the configurations of various APM component. A Config message is
|
|
|
|
|
// added when any of the fields are changed.
|
|
|
|
|
message Config {
|
|
|
|
|
// Acoustic echo canceler.
|
|
|
|
|
optional bool aec_enabled = 1;
|
|
|
|
|
optional bool aec_delay_agnostic_enabled = 2;
|
|
|
|
|
optional bool aec_drift_compensation_enabled = 3;
|
|
|
|
|
optional bool aec_extended_filter_enabled = 4;
|
|
|
|
|
optional int32 aec_suppression_level = 5;
|
|
|
|
|
// Mobile AEC.
|
|
|
|
|
optional bool aecm_enabled = 6;
|
2018-09-28 12:40:47 +02:00
|
|
|
optional bool aecm_comfort_noise_enabled = 7 [deprecated = true];
|
|
|
|
|
optional int32 aecm_routing_mode = 8 [deprecated = true];
|
2015-10-03 00:39:14 +02:00
|
|
|
// Automatic gain controller.
|
|
|
|
|
optional bool agc_enabled = 9;
|
|
|
|
|
optional int32 agc_mode = 10;
|
|
|
|
|
optional bool agc_limiter_enabled = 11;
|
|
|
|
|
optional bool noise_robust_agc_enabled = 12;
|
|
|
|
|
// High pass filter.
|
|
|
|
|
optional bool hpf_enabled = 13;
|
|
|
|
|
// Noise suppression.
|
|
|
|
|
optional bool ns_enabled = 14;
|
|
|
|
|
optional int32 ns_level = 15;
|
|
|
|
|
// Transient suppression.
|
|
|
|
|
optional bool transient_suppression_enabled = 16;
|
2016-04-15 01:19:44 -07:00
|
|
|
// Semicolon-separated string containing experimental feature
|
|
|
|
|
// descriptions.
|
|
|
|
|
optional string experiments_description = 17;
|
2018-08-30 13:01:34 +02:00
|
|
|
reserved 18; // Intelligibility enhancer enabled (deprecated).
|
2018-04-16 13:52:32 +02:00
|
|
|
// Pre amplifier.
|
|
|
|
|
optional bool pre_amplifier_enabled = 19;
|
|
|
|
|
optional float pre_amplifier_fixed_gain_factor = 20;
|
2018-08-30 13:01:34 +02:00
|
|
|
|
|
|
|
|
// Next field number 21.
|
2015-10-03 00:39:14 +02:00
|
|
|
}
|
|
|
|
|
|
2019-11-07 13:22:00 +01:00
|
|
|
message PlayoutAudioDeviceInfo {
|
|
|
|
|
optional int32 id = 1;
|
|
|
|
|
optional int32 max_volume = 2;
|
|
|
|
|
}
|
|
|
|
|
|
2018-09-10 10:18:07 +02:00
|
|
|
message RuntimeSetting {
|
|
|
|
|
optional float capture_pre_gain = 1;
|
|
|
|
|
optional float custom_render_processing_setting = 2;
|
2019-04-26 11:33:37 +02:00
|
|
|
optional float capture_fixed_post_gain = 3;
|
2019-05-10 15:50:02 +02:00
|
|
|
optional int32 playout_volume_change = 4;
|
2019-11-07 13:22:00 +01:00
|
|
|
optional PlayoutAudioDeviceInfo playout_audio_device_change = 5;
|
2020-08-12 08:46:47 +02:00
|
|
|
optional bool capture_output_used = 6;
|
2021-03-15 16:31:04 +00:00
|
|
|
optional float capture_post_gain = 7;
|
2018-09-10 10:18:07 +02:00
|
|
|
}
|
|
|
|
|
|
2011-08-03 21:08:51 +00:00
|
|
|
message Event {
|
|
|
|
|
enum Type {
|
|
|
|
|
INIT = 0;
|
|
|
|
|
REVERSE_STREAM = 1;
|
|
|
|
|
STREAM = 2;
|
2015-10-03 00:39:14 +02:00
|
|
|
CONFIG = 3;
|
|
|
|
|
UNKNOWN_EVENT = 4;
|
2018-09-10 10:18:07 +02:00
|
|
|
RUNTIME_SETTING = 5;
|
2011-08-03 21:08:51 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
required Type type = 1;
|
|
|
|
|
|
|
|
|
|
optional Init init = 2;
|
|
|
|
|
optional ReverseStream reverse_stream = 3;
|
|
|
|
|
optional Stream stream = 4;
|
2015-10-03 00:39:14 +02:00
|
|
|
optional Config config = 5;
|
2018-09-10 10:18:07 +02:00
|
|
|
optional RuntimeSetting runtime_setting = 6;
|
2011-08-03 21:08:51 +00:00
|
|
|
}
|