Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(63)

Side by Side Diff: webrtc/video/video_quality_test.cc

Issue 2469743002: Passed AudioMixer to AudioState::Config. (Closed)
Patch Set: Rebase. GYP removed! Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « webrtc/video/DEPS ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 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 #include "webrtc/video/video_quality_test.h" 10 #include "webrtc/video/video_quality_test.h"
11 11
12 #include <stdio.h> 12 #include <stdio.h>
13 #include <algorithm> 13 #include <algorithm>
14 #include <deque> 14 #include <deque>
15 #include <map> 15 #include <map>
16 #include <sstream> 16 #include <sstream>
17 #include <string> 17 #include <string>
18 #include <vector> 18 #include <vector>
19 19
20 #include "webrtc/base/checks.h" 20 #include "webrtc/base/checks.h"
21 #include "webrtc/base/event.h" 21 #include "webrtc/base/event.h"
22 #include "webrtc/base/format_macros.h" 22 #include "webrtc/base/format_macros.h"
23 #include "webrtc/base/optional.h" 23 #include "webrtc/base/optional.h"
24 #include "webrtc/base/platform_file.h" 24 #include "webrtc/base/platform_file.h"
25 #include "webrtc/base/timeutils.h" 25 #include "webrtc/base/timeutils.h"
26 #include "webrtc/call.h" 26 #include "webrtc/call.h"
27 #include "webrtc/common_video/libyuv/include/webrtc_libyuv.h" 27 #include "webrtc/common_video/libyuv/include/webrtc_libyuv.h"
28 #include "webrtc/logging/rtc_event_log/rtc_event_log.h" 28 #include "webrtc/logging/rtc_event_log/rtc_event_log.h"
29 #include "webrtc/modules/audio_mixer/audio_mixer_impl.h"
29 #include "webrtc/modules/rtp_rtcp/include/rtp_header_parser.h" 30 #include "webrtc/modules/rtp_rtcp/include/rtp_header_parser.h"
30 #include "webrtc/modules/rtp_rtcp/source/rtp_utility.h" 31 #include "webrtc/modules/rtp_rtcp/source/rtp_utility.h"
31 #include "webrtc/system_wrappers/include/cpu_info.h" 32 #include "webrtc/system_wrappers/include/cpu_info.h"
32 #include "webrtc/test/gtest.h" 33 #include "webrtc/test/gtest.h"
33 #include "webrtc/test/layer_filtering_transport.h" 34 #include "webrtc/test/layer_filtering_transport.h"
34 #include "webrtc/test/run_loop.h" 35 #include "webrtc/test/run_loop.h"
35 #include "webrtc/test/statistics.h" 36 #include "webrtc/test/statistics.h"
36 #include "webrtc/test/testsupport/fileutils.h" 37 #include "webrtc/test/testsupport/fileutils.h"
37 #include "webrtc/test/vcm_capturer.h" 38 #include "webrtc/test/vcm_capturer.h"
38 #include "webrtc/test/video_renderer.h" 39 #include "webrtc/test/video_renderer.h"
(...skipping 1295 matching lines...) Expand 10 before | Expand all | Expand 10 after
1334 // match the full stack tests. 1335 // match the full stack tests.
1335 webrtc::RtcEventLogNullImpl event_log; 1336 webrtc::RtcEventLogNullImpl event_log;
1336 Call::Config call_config(&event_log_); 1337 Call::Config call_config(&event_log_);
1337 call_config.bitrate_config = params_.call.call_bitrate_config; 1338 call_config.bitrate_config = params_.call.call_bitrate_config;
1338 1339
1339 ::VoiceEngineState voe; 1340 ::VoiceEngineState voe;
1340 if (params_.audio.enabled) { 1341 if (params_.audio.enabled) {
1341 CreateVoiceEngine(&voe, decoder_factory_); 1342 CreateVoiceEngine(&voe, decoder_factory_);
1342 AudioState::Config audio_state_config; 1343 AudioState::Config audio_state_config;
1343 audio_state_config.voice_engine = voe.voice_engine; 1344 audio_state_config.voice_engine = voe.voice_engine;
1345 audio_state_config.audio_mixer = AudioMixerImpl::Create();
1344 call_config.audio_state = AudioState::Create(audio_state_config); 1346 call_config.audio_state = AudioState::Create(audio_state_config);
1345 } 1347 }
1346 1348
1347 std::unique_ptr<Call> call(Call::Create(call_config)); 1349 std::unique_ptr<Call> call(Call::Create(call_config));
1348 1350
1349 // TODO(minyue): consider if this is a good transport even for audio only 1351 // TODO(minyue): consider if this is a good transport even for audio only
1350 // calls. 1352 // calls.
1351 test::LayerFilteringTransport transport( 1353 test::LayerFilteringTransport transport(
1352 params.pipe, call.get(), kPayloadTypeVP8, kPayloadTypeVP9, 1354 params.pipe, call.get(), kPayloadTypeVP8, kPayloadTypeVP9,
1353 params.video.selected_tl, params_.ss.selected_sl); 1355 params.video.selected_tl, params_.ss.selected_sl);
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
1480 std::ostringstream str; 1482 std::ostringstream str;
1481 str << receive_logs_++; 1483 str << receive_logs_++;
1482 std::string path = 1484 std::string path =
1483 params_.video.encoded_frame_base_path + "." + str.str() + ".recv.ivf"; 1485 params_.video.encoded_frame_base_path + "." + str.str() + ".recv.ivf";
1484 stream->EnableEncodedFrameRecording(rtc::CreatePlatformFile(path), 1486 stream->EnableEncodedFrameRecording(rtc::CreatePlatformFile(path),
1485 10000000); 1487 10000000);
1486 } 1488 }
1487 } 1489 }
1488 1490
1489 } // namespace webrtc 1491 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698