OLD | NEW |
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 <stdio.h> | 10 #include <stdio.h> |
(...skipping 961 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
972 video_receive_configs_[i].rtp.transport_cc = params_.common.send_side_bwe; | 972 video_receive_configs_[i].rtp.transport_cc = params_.common.send_side_bwe; |
973 } | 973 } |
974 } | 974 } |
975 | 975 |
976 void VideoQualityTest::SetupScreenshare() { | 976 void VideoQualityTest::SetupScreenshare() { |
977 RTC_CHECK(params_.screenshare.enabled); | 977 RTC_CHECK(params_.screenshare.enabled); |
978 | 978 |
979 // Fill out codec settings. | 979 // Fill out codec settings. |
980 video_encoder_config_.content_type = VideoEncoderConfig::ContentType::kScreen; | 980 video_encoder_config_.content_type = VideoEncoderConfig::ContentType::kScreen; |
981 if (params_.common.codec == "VP8") { | 981 if (params_.common.codec == "VP8") { |
982 codec_settings_.VP8 = VideoEncoder::GetDefaultVp8Settings(); | 982 VideoCodecVP8 vp8_settings = VideoEncoder::GetDefaultVp8Settings(); |
983 codec_settings_.VP8.denoisingOn = false; | 983 vp8_settings.denoisingOn = false; |
984 codec_settings_.VP8.frameDroppingOn = false; | 984 vp8_settings.frameDroppingOn = false; |
985 codec_settings_.VP8.numberOfTemporalLayers = | 985 vp8_settings.numberOfTemporalLayers = |
986 static_cast<unsigned char>(params_.common.num_temporal_layers); | 986 static_cast<unsigned char>(params_.common.num_temporal_layers); |
987 video_encoder_config_.encoder_specific_settings = &codec_settings_.VP8; | 987 video_encoder_config_.encoder_specific_settings = new rtc::RefCountedObject< |
| 988 VideoEncoderConfig::Vp8EncoderSpecificSettings>(vp8_settings); |
988 } else if (params_.common.codec == "VP9") { | 989 } else if (params_.common.codec == "VP9") { |
989 codec_settings_.VP9 = VideoEncoder::GetDefaultVp9Settings(); | 990 VideoCodecVP9 vp9_settings = VideoEncoder::GetDefaultVp9Settings(); |
990 codec_settings_.VP9.denoisingOn = false; | 991 vp9_settings.denoisingOn = false; |
991 codec_settings_.VP9.frameDroppingOn = false; | 992 vp9_settings.frameDroppingOn = false; |
992 codec_settings_.VP9.numberOfTemporalLayers = | 993 vp9_settings.numberOfTemporalLayers = |
993 static_cast<unsigned char>(params_.common.num_temporal_layers); | 994 static_cast<unsigned char>(params_.common.num_temporal_layers); |
994 video_encoder_config_.encoder_specific_settings = &codec_settings_.VP9; | 995 vp9_settings.numberOfSpatialLayers = |
995 codec_settings_.VP9.numberOfSpatialLayers = | |
996 static_cast<unsigned char>(params_.ss.num_spatial_layers); | 996 static_cast<unsigned char>(params_.ss.num_spatial_layers); |
| 997 video_encoder_config_.encoder_specific_settings = new rtc::RefCountedObject< |
| 998 VideoEncoderConfig::Vp9EncoderSpecificSettings>(vp9_settings); |
997 } | 999 } |
998 | 1000 |
999 // Setup frame generator. | 1001 // Setup frame generator. |
1000 const size_t kWidth = 1850; | 1002 const size_t kWidth = 1850; |
1001 const size_t kHeight = 1110; | 1003 const size_t kHeight = 1110; |
1002 std::vector<std::string> slides; | 1004 std::vector<std::string> slides; |
1003 slides.push_back(test::ResourcePath("web_screenshot_1850_1110", "yuv")); | 1005 slides.push_back(test::ResourcePath("web_screenshot_1850_1110", "yuv")); |
1004 slides.push_back(test::ResourcePath("presentation_1850_1110", "yuv")); | 1006 slides.push_back(test::ResourcePath("presentation_1850_1110", "yuv")); |
1005 slides.push_back(test::ResourcePath("photo_1850_1110", "yuv")); | 1007 slides.push_back(test::ResourcePath("photo_1850_1110", "yuv")); |
1006 slides.push_back(test::ResourcePath("difficult_photo_1850_1110", "yuv")); | 1008 slides.push_back(test::ResourcePath("difficult_photo_1850_1110", "yuv")); |
(...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1301 call->DestroyAudioSendStream(audio_send_stream_); | 1303 call->DestroyAudioSendStream(audio_send_stream_); |
1302 call->DestroyAudioReceiveStream(audio_receive_stream); | 1304 call->DestroyAudioReceiveStream(audio_receive_stream); |
1303 } | 1305 } |
1304 | 1306 |
1305 transport.StopSending(); | 1307 transport.StopSending(); |
1306 if (params_.audio) | 1308 if (params_.audio) |
1307 DestroyVoiceEngine(&voe); | 1309 DestroyVoiceEngine(&voe); |
1308 } | 1310 } |
1309 | 1311 |
1310 } // namespace webrtc | 1312 } // namespace webrtc |
OLD | NEW |