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 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
291 | 291 |
292 _outputFileRecorderPtr = | 292 _outputFileRecorderPtr = |
293 FileRecorder::CreateFileRecorder(_instanceId, (const FileFormats)format); | 293 FileRecorder::CreateFileRecorder(_instanceId, (const FileFormats)format); |
294 if (_outputFileRecorderPtr == NULL) { | 294 if (_outputFileRecorderPtr == NULL) { |
295 _engineStatisticsPtr->SetLastError( | 295 _engineStatisticsPtr->SetLastError( |
296 VE_INVALID_ARGUMENT, kTraceError, | 296 VE_INVALID_ARGUMENT, kTraceError, |
297 "StartRecordingPlayout() fileRecorder format isnot correct"); | 297 "StartRecordingPlayout() fileRecorder format isnot correct"); |
298 return -1; | 298 return -1; |
299 } | 299 } |
300 | 300 |
301 if (_outputFileRecorderPtr->StartRecordingAudioFile(*stream, *codecInst, | 301 if (_outputFileRecorderPtr->StartRecordingAudioFile(stream, *codecInst, |
302 notificationTime) != 0) { | 302 notificationTime) != 0) { |
303 _engineStatisticsPtr->SetLastError( | 303 _engineStatisticsPtr->SetLastError( |
304 VE_BAD_FILE, kTraceError, | 304 VE_BAD_FILE, kTraceError, |
305 "StartRecordingAudioFile() failed to start file recording"); | 305 "StartRecordingAudioFile() failed to start file recording"); |
306 _outputFileRecorderPtr->StopRecording(); | 306 _outputFileRecorderPtr->StopRecording(); |
307 _outputFileRecorderPtr.reset(); | 307 _outputFileRecorderPtr.reset(); |
308 return -1; | 308 return -1; |
309 } | 309 } |
310 | 310 |
311 _outputFileRecorderPtr->RegisterModuleFileCallback(this); | 311 _outputFileRecorderPtr->RegisterModuleFileCallback(this); |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 } | 404 } |
405 } | 405 } |
406 | 406 |
407 // --- Measure audio level (0-9) for the combined signal | 407 // --- Measure audio level (0-9) for the combined signal |
408 _audioLevel.ComputeLevel(_audioFrame); | 408 _audioLevel.ComputeLevel(_audioFrame); |
409 | 409 |
410 return 0; | 410 return 0; |
411 } | 411 } |
412 } // namespace voe | 412 } // namespace voe |
413 } // namespace webrtc | 413 } // namespace webrtc |
OLD | NEW |