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 614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
625 capture_.capture_audio->CopyTo(formats_.api_format.output_stream(), dest); | 625 capture_.capture_audio->CopyTo(formats_.api_format.output_stream(), dest); |
626 | 626 |
627 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 627 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
628 if (debug_dump_.debug_file->Open()) { | 628 if (debug_dump_.debug_file->Open()) { |
629 audioproc::Stream* msg = debug_dump_.capture.event_msg->mutable_stream(); | 629 audioproc::Stream* msg = debug_dump_.capture.event_msg->mutable_stream(); |
630 const size_t channel_size = | 630 const size_t channel_size = |
631 sizeof(float) * formats_.api_format.output_stream().num_frames(); | 631 sizeof(float) * formats_.api_format.output_stream().num_frames(); |
632 for (int i = 0; i < formats_.api_format.output_stream().num_channels(); ++i) | 632 for (int i = 0; i < formats_.api_format.output_stream().num_channels(); ++i) |
633 msg->add_output_channel(dest[i], channel_size); | 633 msg->add_output_channel(dest[i], channel_size); |
634 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 634 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
| 635 &debug_dump_.num_bytes_left_for_log_, |
635 &crit_debug_, &debug_dump_.capture)); | 636 &crit_debug_, &debug_dump_.capture)); |
636 } | 637 } |
637 #endif | 638 #endif |
638 | 639 |
639 return kNoError; | 640 return kNoError; |
640 } | 641 } |
641 | 642 |
642 int AudioProcessingImpl::ProcessStream(AudioFrame* frame) { | 643 int AudioProcessingImpl::ProcessStream(AudioFrame* frame) { |
643 TRACE_EVENT0("webrtc", "AudioProcessing::ProcessStream_AudioFrame"); | 644 TRACE_EVENT0("webrtc", "AudioProcessing::ProcessStream_AudioFrame"); |
644 { | 645 { |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
712 capture_.capture_audio->InterleaveTo(frame, | 713 capture_.capture_audio->InterleaveTo(frame, |
713 output_copy_needed(is_data_processed())); | 714 output_copy_needed(is_data_processed())); |
714 | 715 |
715 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 716 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
716 if (debug_dump_.debug_file->Open()) { | 717 if (debug_dump_.debug_file->Open()) { |
717 audioproc::Stream* msg = debug_dump_.capture.event_msg->mutable_stream(); | 718 audioproc::Stream* msg = debug_dump_.capture.event_msg->mutable_stream(); |
718 const size_t data_size = | 719 const size_t data_size = |
719 sizeof(int16_t) * frame->samples_per_channel_ * frame->num_channels_; | 720 sizeof(int16_t) * frame->samples_per_channel_ * frame->num_channels_; |
720 msg->set_output_data(frame->data_, data_size); | 721 msg->set_output_data(frame->data_, data_size); |
721 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 722 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
| 723 &debug_dump_.num_bytes_left_for_log_, |
722 &crit_debug_, &debug_dump_.capture)); | 724 &crit_debug_, &debug_dump_.capture)); |
723 } | 725 } |
724 #endif | 726 #endif |
725 | 727 |
726 return kNoError; | 728 return kNoError; |
727 } | 729 } |
728 | 730 |
729 int AudioProcessingImpl::ProcessStreamLocked() { | 731 int AudioProcessingImpl::ProcessStreamLocked() { |
730 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 732 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
731 if (debug_dump_.debug_file->Open()) { | 733 if (debug_dump_.debug_file->Open()) { |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
879 if (debug_dump_.debug_file->Open()) { | 881 if (debug_dump_.debug_file->Open()) { |
880 debug_dump_.render.event_msg->set_type(audioproc::Event::REVERSE_STREAM); | 882 debug_dump_.render.event_msg->set_type(audioproc::Event::REVERSE_STREAM); |
881 audioproc::ReverseStream* msg = | 883 audioproc::ReverseStream* msg = |
882 debug_dump_.render.event_msg->mutable_reverse_stream(); | 884 debug_dump_.render.event_msg->mutable_reverse_stream(); |
883 const size_t channel_size = | 885 const size_t channel_size = |
884 sizeof(float) * formats_.api_format.reverse_input_stream().num_frames(); | 886 sizeof(float) * formats_.api_format.reverse_input_stream().num_frames(); |
885 for (int i = 0; | 887 for (int i = 0; |
886 i < formats_.api_format.reverse_input_stream().num_channels(); ++i) | 888 i < formats_.api_format.reverse_input_stream().num_channels(); ++i) |
887 msg->add_channel(src[i], channel_size); | 889 msg->add_channel(src[i], channel_size); |
888 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 890 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
| 891 &debug_dump_.num_bytes_left_for_log_, |
889 &crit_debug_, &debug_dump_.render)); | 892 &crit_debug_, &debug_dump_.render)); |
890 } | 893 } |
891 #endif | 894 #endif |
892 | 895 |
893 render_.render_audio->CopyFrom(src, | 896 render_.render_audio->CopyFrom(src, |
894 formats_.api_format.reverse_input_stream()); | 897 formats_.api_format.reverse_input_stream()); |
895 return ProcessReverseStreamLocked(); | 898 return ProcessReverseStreamLocked(); |
896 } | 899 } |
897 | 900 |
898 int AudioProcessingImpl::ProcessReverseStream(AudioFrame* frame) { | 901 int AudioProcessingImpl::ProcessReverseStream(AudioFrame* frame) { |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
947 | 950 |
948 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 951 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
949 if (debug_dump_.debug_file->Open()) { | 952 if (debug_dump_.debug_file->Open()) { |
950 debug_dump_.render.event_msg->set_type(audioproc::Event::REVERSE_STREAM); | 953 debug_dump_.render.event_msg->set_type(audioproc::Event::REVERSE_STREAM); |
951 audioproc::ReverseStream* msg = | 954 audioproc::ReverseStream* msg = |
952 debug_dump_.render.event_msg->mutable_reverse_stream(); | 955 debug_dump_.render.event_msg->mutable_reverse_stream(); |
953 const size_t data_size = | 956 const size_t data_size = |
954 sizeof(int16_t) * frame->samples_per_channel_ * frame->num_channels_; | 957 sizeof(int16_t) * frame->samples_per_channel_ * frame->num_channels_; |
955 msg->set_data(frame->data_, data_size); | 958 msg->set_data(frame->data_, data_size); |
956 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 959 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
| 960 &debug_dump_.num_bytes_left_for_log_, |
957 &crit_debug_, &debug_dump_.render)); | 961 &crit_debug_, &debug_dump_.render)); |
958 } | 962 } |
959 #endif | 963 #endif |
960 render_.render_audio->DeinterleaveFrom(frame); | 964 render_.render_audio->DeinterleaveFrom(frame); |
961 return ProcessReverseStreamLocked(); | 965 return ProcessReverseStreamLocked(); |
962 } | 966 } |
963 | 967 |
964 int AudioProcessingImpl::ProcessReverseStreamLocked() { | 968 int AudioProcessingImpl::ProcessReverseStreamLocked() { |
965 AudioBuffer* ra = render_.render_audio.get(); // For brevity. | 969 AudioBuffer* ra = render_.render_audio.get(); // For brevity. |
966 if (formats_.rev_proc_format.sample_rate_hz() == kSampleRate32kHz) { | 970 if (formats_.rev_proc_format.sample_rate_hz() == kSampleRate32kHz) { |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1032 rtc::CritScope cs(&crit_capture_); | 1036 rtc::CritScope cs(&crit_capture_); |
1033 capture_.delay_offset_ms = offset; | 1037 capture_.delay_offset_ms = offset; |
1034 } | 1038 } |
1035 | 1039 |
1036 int AudioProcessingImpl::delay_offset_ms() const { | 1040 int AudioProcessingImpl::delay_offset_ms() const { |
1037 rtc::CritScope cs(&crit_capture_); | 1041 rtc::CritScope cs(&crit_capture_); |
1038 return capture_.delay_offset_ms; | 1042 return capture_.delay_offset_ms; |
1039 } | 1043 } |
1040 | 1044 |
1041 int AudioProcessingImpl::StartDebugRecording( | 1045 int AudioProcessingImpl::StartDebugRecording( |
1042 const char filename[AudioProcessing::kMaxFilenameSize]) { | 1046 const char filename[AudioProcessing::kMaxFilenameSize], |
| 1047 int64_t max_log_size_bytes) { |
1043 // Run in a single-threaded manner. | 1048 // Run in a single-threaded manner. |
1044 rtc::CritScope cs_render(&crit_render_); | 1049 rtc::CritScope cs_render(&crit_render_); |
1045 rtc::CritScope cs_capture(&crit_capture_); | 1050 rtc::CritScope cs_capture(&crit_capture_); |
1046 static_assert(kMaxFilenameSize == FileWrapper::kMaxFileNameSize, ""); | 1051 static_assert(kMaxFilenameSize == FileWrapper::kMaxFileNameSize, ""); |
1047 | 1052 |
1048 if (filename == nullptr) { | 1053 if (filename == nullptr) { |
1049 return kNullPointerError; | 1054 return kNullPointerError; |
1050 } | 1055 } |
1051 | 1056 |
1052 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 1057 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
| 1058 debug_dump_.num_bytes_left_for_log_ = max_log_size_bytes; |
1053 // Stop any ongoing recording. | 1059 // Stop any ongoing recording. |
1054 if (debug_dump_.debug_file->Open()) { | 1060 if (debug_dump_.debug_file->Open()) { |
1055 if (debug_dump_.debug_file->CloseFile() == -1) { | 1061 if (debug_dump_.debug_file->CloseFile() == -1) { |
1056 return kFileError; | 1062 return kFileError; |
1057 } | 1063 } |
1058 } | 1064 } |
1059 | 1065 |
1060 if (debug_dump_.debug_file->OpenFile(filename, false) == -1) { | 1066 if (debug_dump_.debug_file->OpenFile(filename, false) == -1) { |
1061 debug_dump_.debug_file->CloseFile(); | 1067 debug_dump_.debug_file->CloseFile(); |
1062 return kFileError; | 1068 return kFileError; |
1063 } | 1069 } |
1064 | 1070 |
1065 RETURN_ON_ERR(WriteConfigMessage(true)); | 1071 RETURN_ON_ERR(WriteConfigMessage(true)); |
1066 RETURN_ON_ERR(WriteInitMessage()); | 1072 RETURN_ON_ERR(WriteInitMessage()); |
1067 return kNoError; | 1073 return kNoError; |
1068 #else | 1074 #else |
1069 return kUnsupportedFunctionError; | 1075 return kUnsupportedFunctionError; |
1070 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP | 1076 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP |
1071 } | 1077 } |
1072 | 1078 |
1073 int AudioProcessingImpl::StartDebugRecording(FILE* handle) { | 1079 int AudioProcessingImpl::StartDebugRecording(FILE* handle, |
| 1080 int64_t max_log_size_bytes) { |
1074 // Run in a single-threaded manner. | 1081 // Run in a single-threaded manner. |
1075 rtc::CritScope cs_render(&crit_render_); | 1082 rtc::CritScope cs_render(&crit_render_); |
1076 rtc::CritScope cs_capture(&crit_capture_); | 1083 rtc::CritScope cs_capture(&crit_capture_); |
1077 | 1084 |
1078 if (handle == nullptr) { | 1085 if (handle == nullptr) { |
1079 return kNullPointerError; | 1086 return kNullPointerError; |
1080 } | 1087 } |
1081 | 1088 |
1082 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 1089 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
| 1090 debug_dump_.num_bytes_left_for_log_ = max_log_size_bytes; |
| 1091 |
1083 // Stop any ongoing recording. | 1092 // Stop any ongoing recording. |
1084 if (debug_dump_.debug_file->Open()) { | 1093 if (debug_dump_.debug_file->Open()) { |
1085 if (debug_dump_.debug_file->CloseFile() == -1) { | 1094 if (debug_dump_.debug_file->CloseFile() == -1) { |
1086 return kFileError; | 1095 return kFileError; |
1087 } | 1096 } |
1088 } | 1097 } |
1089 | 1098 |
1090 if (debug_dump_.debug_file->OpenFromFileHandle(handle, true, false) == -1) { | 1099 if (debug_dump_.debug_file->OpenFromFileHandle(handle, true, false) == -1) { |
1091 return kFileError; | 1100 return kFileError; |
1092 } | 1101 } |
1093 | 1102 |
1094 RETURN_ON_ERR(WriteConfigMessage(true)); | 1103 RETURN_ON_ERR(WriteConfigMessage(true)); |
1095 RETURN_ON_ERR(WriteInitMessage()); | 1104 RETURN_ON_ERR(WriteInitMessage()); |
1096 return kNoError; | 1105 return kNoError; |
1097 #else | 1106 #else |
1098 return kUnsupportedFunctionError; | 1107 return kUnsupportedFunctionError; |
1099 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP | 1108 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP |
1100 } | 1109 } |
1101 | 1110 |
1102 int AudioProcessingImpl::StartDebugRecordingForPlatformFile( | 1111 int AudioProcessingImpl::StartDebugRecordingForPlatformFile( |
1103 rtc::PlatformFile handle) { | 1112 rtc::PlatformFile handle) { |
1104 // Run in a single-threaded manner. | 1113 // Run in a single-threaded manner. |
1105 rtc::CritScope cs_render(&crit_render_); | 1114 rtc::CritScope cs_render(&crit_render_); |
1106 rtc::CritScope cs_capture(&crit_capture_); | 1115 rtc::CritScope cs_capture(&crit_capture_); |
1107 FILE* stream = rtc::FdopenPlatformFileForWriting(handle); | 1116 FILE* stream = rtc::FdopenPlatformFileForWriting(handle); |
1108 return StartDebugRecording(stream); | 1117 return StartDebugRecording(stream, -1); |
1109 } | 1118 } |
1110 | 1119 |
1111 int AudioProcessingImpl::StopDebugRecording() { | 1120 int AudioProcessingImpl::StopDebugRecording() { |
1112 // Run in a single-threaded manner. | 1121 // Run in a single-threaded manner. |
1113 rtc::CritScope cs_render(&crit_render_); | 1122 rtc::CritScope cs_render(&crit_render_); |
1114 rtc::CritScope cs_capture(&crit_capture_); | 1123 rtc::CritScope cs_capture(&crit_capture_); |
1115 | 1124 |
1116 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 1125 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
1117 // We just return if recording hasn't started. | 1126 // We just return if recording hasn't started. |
1118 if (debug_dump_.debug_file->Open()) { | 1127 if (debug_dump_.debug_file->Open()) { |
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1393 RTC_HISTOGRAM_ENUMERATION("WebRTC.Audio.NumOfAecSystemDelayJumps", | 1402 RTC_HISTOGRAM_ENUMERATION("WebRTC.Audio.NumOfAecSystemDelayJumps", |
1394 capture_.aec_system_delay_jumps, 51); | 1403 capture_.aec_system_delay_jumps, 51); |
1395 } | 1404 } |
1396 capture_.aec_system_delay_jumps = -1; | 1405 capture_.aec_system_delay_jumps = -1; |
1397 capture_.last_aec_system_delay_ms = 0; | 1406 capture_.last_aec_system_delay_ms = 0; |
1398 } | 1407 } |
1399 | 1408 |
1400 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP | 1409 #ifdef WEBRTC_AUDIOPROC_DEBUG_DUMP |
1401 int AudioProcessingImpl::WriteMessageToDebugFile( | 1410 int AudioProcessingImpl::WriteMessageToDebugFile( |
1402 FileWrapper* debug_file, | 1411 FileWrapper* debug_file, |
| 1412 int64_t* filesize_limit_bytes, |
1403 rtc::CriticalSection* crit_debug, | 1413 rtc::CriticalSection* crit_debug, |
1404 ApmDebugDumpThreadState* debug_state) { | 1414 ApmDebugDumpThreadState* debug_state) { |
1405 int32_t size = debug_state->event_msg->ByteSize(); | 1415 int32_t size = debug_state->event_msg->ByteSize(); |
1406 if (size <= 0) { | 1416 if (size <= 0) { |
1407 return kUnspecifiedError; | 1417 return kUnspecifiedError; |
1408 } | 1418 } |
1409 #if defined(WEBRTC_ARCH_BIG_ENDIAN) | 1419 #if defined(WEBRTC_ARCH_BIG_ENDIAN) |
1410 // TODO(ajm): Use little-endian "on the wire". For the moment, we can be | 1420 // TODO(ajm): Use little-endian "on the wire". For the moment, we can be |
1411 // pretty safe in assuming little-endian. | 1421 // pretty safe in assuming little-endian. |
1412 #endif | 1422 #endif |
1413 | 1423 |
1414 if (!debug_state->event_msg->SerializeToString(&debug_state->event_str)) { | 1424 if (!debug_state->event_msg->SerializeToString(&debug_state->event_str)) { |
1415 return kUnspecifiedError; | 1425 return kUnspecifiedError; |
1416 } | 1426 } |
1417 | 1427 |
1418 { | 1428 { |
1419 // Ensure atomic writes of the message. | 1429 // Ensure atomic writes of the message. |
1420 rtc::CritScope cs_capture(crit_debug); | 1430 rtc::CritScope cs_debug(crit_debug); |
| 1431 |
| 1432 RTC_DCHECK(debug_file->Open()); |
| 1433 // Update the byte counter. |
| 1434 if (*filesize_limit_bytes >= 0) { |
| 1435 *filesize_limit_bytes -= |
| 1436 (sizeof(int32_t) + debug_state->event_str.length()); |
| 1437 if (*filesize_limit_bytes < 0) { |
| 1438 // Not enough bytes are left to write this message, so stop logging. |
| 1439 debug_file->CloseFile(); |
| 1440 return kNoError; |
| 1441 } |
| 1442 } |
1421 // Write message preceded by its size. | 1443 // Write message preceded by its size. |
1422 if (!debug_file->Write(&size, sizeof(int32_t))) { | 1444 if (!debug_file->Write(&size, sizeof(int32_t))) { |
1423 return kFileError; | 1445 return kFileError; |
1424 } | 1446 } |
1425 if (!debug_file->Write(debug_state->event_str.data(), | 1447 if (!debug_file->Write(debug_state->event_str.data(), |
1426 debug_state->event_str.length())) { | 1448 debug_state->event_str.length())) { |
1427 return kFileError; | 1449 return kFileError; |
1428 } | 1450 } |
1429 } | 1451 } |
1430 | 1452 |
(...skipping 14 matching lines...) Expand all Loading... |
1445 msg->set_num_reverse_channels( | 1467 msg->set_num_reverse_channels( |
1446 formats_.api_format.reverse_input_stream().num_channels()); | 1468 formats_.api_format.reverse_input_stream().num_channels()); |
1447 msg->set_reverse_sample_rate( | 1469 msg->set_reverse_sample_rate( |
1448 formats_.api_format.reverse_input_stream().sample_rate_hz()); | 1470 formats_.api_format.reverse_input_stream().sample_rate_hz()); |
1449 msg->set_output_sample_rate( | 1471 msg->set_output_sample_rate( |
1450 formats_.api_format.output_stream().sample_rate_hz()); | 1472 formats_.api_format.output_stream().sample_rate_hz()); |
1451 // TODO(ekmeyerson): Add reverse output fields to | 1473 // TODO(ekmeyerson): Add reverse output fields to |
1452 // debug_dump_.capture.event_msg. | 1474 // debug_dump_.capture.event_msg. |
1453 | 1475 |
1454 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 1476 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
| 1477 &debug_dump_.num_bytes_left_for_log_, |
1455 &crit_debug_, &debug_dump_.capture)); | 1478 &crit_debug_, &debug_dump_.capture)); |
1456 return kNoError; | 1479 return kNoError; |
1457 } | 1480 } |
1458 | 1481 |
1459 int AudioProcessingImpl::WriteConfigMessage(bool forced) { | 1482 int AudioProcessingImpl::WriteConfigMessage(bool forced) { |
1460 audioproc::Config config; | 1483 audioproc::Config config; |
1461 | 1484 |
1462 config.set_aec_enabled(public_submodules_->echo_cancellation->is_enabled()); | 1485 config.set_aec_enabled(public_submodules_->echo_cancellation->is_enabled()); |
1463 config.set_aec_delay_agnostic_enabled( | 1486 config.set_aec_delay_agnostic_enabled( |
1464 public_submodules_->echo_cancellation->is_delay_agnostic_enabled()); | 1487 public_submodules_->echo_cancellation->is_delay_agnostic_enabled()); |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1497 debug_dump_.capture.last_serialized_config == serialized_config) { | 1520 debug_dump_.capture.last_serialized_config == serialized_config) { |
1498 return kNoError; | 1521 return kNoError; |
1499 } | 1522 } |
1500 | 1523 |
1501 debug_dump_.capture.last_serialized_config = serialized_config; | 1524 debug_dump_.capture.last_serialized_config = serialized_config; |
1502 | 1525 |
1503 debug_dump_.capture.event_msg->set_type(audioproc::Event::CONFIG); | 1526 debug_dump_.capture.event_msg->set_type(audioproc::Event::CONFIG); |
1504 debug_dump_.capture.event_msg->mutable_config()->CopyFrom(config); | 1527 debug_dump_.capture.event_msg->mutable_config()->CopyFrom(config); |
1505 | 1528 |
1506 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 1529 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
| 1530 &debug_dump_.num_bytes_left_for_log_, |
1507 &crit_debug_, &debug_dump_.capture)); | 1531 &crit_debug_, &debug_dump_.capture)); |
1508 return kNoError; | 1532 return kNoError; |
1509 } | 1533 } |
1510 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP | 1534 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP |
1511 | 1535 |
1512 } // namespace webrtc | 1536 } // namespace webrtc |
OLD | NEW |