Optional: Use nullopt and implicit construction in /logging
Changes places where we explicitly construct an Optional to instead use nullopt or the requisite value type only. This CL was uploaded by git cl split. Bug: None Change-Id: Ibe15d2814074a4cf67de18d6e04540076f1a9dc9 Reviewed-on: https://webrtc-review.googlesource.com/23611 Reviewed-by: Björn Terelius <terelius@webrtc.org> Commit-Queue: Oskar Sundbom <ossu@webrtc.org> Cr-Commit-Position: refs/heads/master@{#20862}
This commit is contained in:
committed by
Commit Bot
parent
6196feb2ed
commit
f281853c11
@ -291,13 +291,12 @@ BweLossEvent GenerateBweLossEvent(Random* prng) {
|
||||
void GenerateAudioNetworkAdaptation(const RtpHeaderExtensionMap& extensions,
|
||||
AudioEncoderRuntimeConfig* config,
|
||||
Random* prng) {
|
||||
config->bitrate_bps = rtc::Optional<int>(prng->Rand(0, 3000000));
|
||||
config->enable_fec = rtc::Optional<bool>(prng->Rand<bool>());
|
||||
config->enable_dtx = rtc::Optional<bool>(prng->Rand<bool>());
|
||||
config->frame_length_ms = rtc::Optional<int>(prng->Rand(10, 120));
|
||||
config->num_channels = rtc::Optional<size_t>(prng->Rand(1, 2));
|
||||
config->uplink_packet_loss_fraction =
|
||||
rtc::Optional<float>(prng->Rand<float>());
|
||||
config->bitrate_bps = prng->Rand(0, 3000000);
|
||||
config->enable_fec = prng->Rand<bool>();
|
||||
config->enable_dtx = prng->Rand<bool>();
|
||||
config->frame_length_ms = prng->Rand(10, 120);
|
||||
config->num_channels = prng->Rand(1, 2);
|
||||
config->uplink_packet_loss_fraction = prng->Rand<float>();
|
||||
}
|
||||
|
||||
class RtcEventLogSession
|
||||
|
||||
Reference in New Issue
Block a user