Clean up FlexfecReceiveStream ctor signatures.
BUG=webrtc:5654 Review-Url: https://codereview.webrtc.org/2535173008 Cr-Commit-Position: refs/heads/master@{#15476}
This commit is contained in:
parent
64c4a7ecfc
commit
446fcb6cad
@ -92,7 +92,7 @@ class Call : public webrtc::Call,
|
||||
webrtc::VideoReceiveStream* receive_stream) override;
|
||||
|
||||
webrtc::FlexfecReceiveStream* CreateFlexfecReceiveStream(
|
||||
webrtc::FlexfecReceiveStream::Config configuration) override;
|
||||
const webrtc::FlexfecReceiveStream::Config& config) override;
|
||||
void DestroyFlexfecReceiveStream(
|
||||
webrtc::FlexfecReceiveStream* receive_stream) override;
|
||||
|
||||
@ -656,13 +656,11 @@ void Call::DestroyVideoReceiveStream(
|
||||
}
|
||||
|
||||
webrtc::FlexfecReceiveStream* Call::CreateFlexfecReceiveStream(
|
||||
webrtc::FlexfecReceiveStream::Config configuration) {
|
||||
const webrtc::FlexfecReceiveStream::Config& config) {
|
||||
TRACE_EVENT0("webrtc", "Call::CreateFlexfecReceiveStream");
|
||||
RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread());
|
||||
FlexfecReceiveStream* receive_stream =
|
||||
new FlexfecReceiveStream(std::move(configuration), this);
|
||||
FlexfecReceiveStream* receive_stream = new FlexfecReceiveStream(config, this);
|
||||
|
||||
const webrtc::FlexfecReceiveStream::Config& config = receive_stream->config();
|
||||
{
|
||||
WriteLockScoped write_lock(*receive_crit_);
|
||||
for (auto ssrc : config.protected_media_ssrcs)
|
||||
|
||||
@ -120,7 +120,7 @@ class Call {
|
||||
VideoReceiveStream* receive_stream) = 0;
|
||||
|
||||
virtual FlexfecReceiveStream* CreateFlexfecReceiveStream(
|
||||
FlexfecReceiveStream::Config configuration) = 0;
|
||||
const FlexfecReceiveStream::Config& config) = 0;
|
||||
virtual void DestroyFlexfecReceiveStream(
|
||||
FlexfecReceiveStream* receive_stream) = 0;
|
||||
|
||||
|
||||
@ -65,10 +65,10 @@ std::unique_ptr<FlexfecReceiver> MaybeCreateFlexfecReceiver(
|
||||
namespace internal {
|
||||
|
||||
FlexfecReceiveStream::FlexfecReceiveStream(
|
||||
Config configuration,
|
||||
const Config& config,
|
||||
RecoveredPacketReceiver* recovered_packet_callback)
|
||||
: started_(false),
|
||||
config_(configuration),
|
||||
config_(config),
|
||||
receiver_(
|
||||
MaybeCreateFlexfecReceiver(config_, recovered_packet_callback)) {
|
||||
LOG(LS_INFO) << "FlexfecReceiveStream: " << config_.ToString();
|
||||
|
||||
@ -25,12 +25,10 @@ namespace internal {
|
||||
|
||||
class FlexfecReceiveStream : public webrtc::FlexfecReceiveStream {
|
||||
public:
|
||||
FlexfecReceiveStream(Config configuration,
|
||||
FlexfecReceiveStream(const Config& config,
|
||||
RecoveredPacketReceiver* recovered_packet_callback);
|
||||
~FlexfecReceiveStream();
|
||||
|
||||
const Config& config() const { return config_; }
|
||||
|
||||
bool AddAndProcessReceivedPacket(const uint8_t* packet, size_t length);
|
||||
|
||||
// Implements webrtc::FlexfecReceiveStream.
|
||||
|
||||
@ -477,9 +477,8 @@ void FakeCall::DestroyVideoReceiveStream(
|
||||
}
|
||||
|
||||
webrtc::FlexfecReceiveStream* FakeCall::CreateFlexfecReceiveStream(
|
||||
webrtc::FlexfecReceiveStream::Config config) {
|
||||
flexfec_receive_streams_.push_back(
|
||||
FakeFlexfecReceiveStream(std::move(config)));
|
||||
const webrtc::FlexfecReceiveStream::Config& config) {
|
||||
flexfec_receive_streams_.push_back(FakeFlexfecReceiveStream(config));
|
||||
++num_created_receive_streams_;
|
||||
return &flexfec_receive_streams_.back();
|
||||
}
|
||||
|
||||
@ -265,7 +265,7 @@ class FakeCall final : public webrtc::Call, public webrtc::PacketReceiver {
|
||||
webrtc::VideoReceiveStream* receive_stream) override;
|
||||
|
||||
webrtc::FlexfecReceiveStream* CreateFlexfecReceiveStream(
|
||||
webrtc::FlexfecReceiveStream::Config config) override;
|
||||
const webrtc::FlexfecReceiveStream::Config& config) override;
|
||||
void DestroyFlexfecReceiveStream(
|
||||
webrtc::FlexfecReceiveStream* receive_stream) override;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user