Index: talk/media/webrtc/webrtcvoiceengine.cc |
diff --git a/talk/media/webrtc/webrtcvoiceengine.cc b/talk/media/webrtc/webrtcvoiceengine.cc |
index eed1195975704aea781d564eefca5a9953b164d4..67f88c9f1ad0ecc03aad66673f49202e63f6d41f 100644 |
--- a/talk/media/webrtc/webrtcvoiceengine.cc |
+++ b/talk/media/webrtc/webrtcvoiceengine.cc |
@@ -1278,6 +1278,27 @@ bool WebRtcVoiceEngine::StartAecDump(rtc::PlatformFile file) { |
return true; |
} |
+bool WebRtcVoiceEngine::StartAecDump(rtc::PlatformFile file, |
+ int max_size_bytes) { |
+ FILE* aec_dump_file_stream = rtc::FdopenPlatformFileForWriting(file); |
+ if (!aec_dump_file_stream) { |
+ LOG(LS_ERROR) << "Could not open AEC dump file stream."; |
+ if (!rtc::ClosePlatformFile(file)) |
+ LOG(LS_WARNING) << "Could not close file."; |
+ return false; |
+ } |
+ StopAecDump(); |
+ if (voe_wrapper_->processing()->StartDebugRecording(aec_dump_file_stream, |
+ max_size_bytes) != |
+ webrtc::AudioProcessing::kNoError) { |
+ LOG_RTCERR0(StartDebugRecording); |
+ fclose(aec_dump_file_stream); |
+ return false; |
+ } |
+ is_dumping_aec_ = true; |
+ return true; |
+} |
kwiberg-webrtc
2015/10/25 02:29:12
This duplicates a lot of the preceding function. C
the sun
2015/10/26 10:37:20
See previous comment in PeerConnectionFactory: we
ivoc
2015/11/05 13:14:45
Done.
|
+ |
void WebRtcVoiceEngine::StartAecDump(const std::string& filename) { |
if (!is_dumping_aec_) { |
// Start dumping AEC when we are not dumping. |